	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function md_open
_md_open:                               ## @md_open
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movl	8(%rdi), %edi
	callq	_mddev_find
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movq	%rax, %rbx
	movq	8(%rax), %rax
	cmpq	(%r14), %rax
	je	LBB0_5
## %bb.4:
	movq	%rbx, %rdi
	callq	_mddev_put
	movq	_md_misc_wq@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_flush_workqueue
	movq	_ERESTARTSYS@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_1:
	movq	_ENODEV@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_7:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_5:
	xorl	%edi, %edi
	cmpq	(%rax), %rbx
	setne	%dil
	callq	_BUG_ON
	movq	%rbx, %rdi
	callq	_mutex_lock_interruptible
	testl	%eax, %eax
	jne	LBB0_7
## %bb.6:
	movq	%rbx, %rdi
	addq	$4, %rdi
	callq	_atomic_inc
	movq	%rbx, %rdi
	callq	_mutex_unlock
	movq	%r14, %rdi
	callq	_check_disk_change
	xorl	%eax, %eax
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_md_misc_wq,4,2                 ## @md_misc_wq
	.comm	_ERESTARTSYS,4,2                ## @ERESTARTSYS
	.no_dead_strip	_md_open
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function md_open
_md_open:                               ; @md_open
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	w0, [x0, #8]
	bl	_mddev_find
	cbz	x0, LBB0_3
; %bb.1:
	mov	x20, x0
	ldr	x8, [x0, #8]
	ldr	x9, [x19]
	cmp	x8, x9
	b.eq	LBB0_6
; %bb.2:
	mov	x0, x20
	bl	_mddev_put
Lloh0:
	adrp	x8, _md_misc_wq@GOTPAGE
Lloh1:
	ldr	x8, [x8, _md_misc_wq@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_flush_workqueue
Lloh3:
	adrp	x8, _ERESTARTSYS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ERESTARTSYS@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:
Lloh5:
	adrp	x8, _ENODEV@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_5:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_6:
	ldr	x8, [x8]
	cmp	x20, x8
	cset	w0, ne
	bl	_BUG_ON
	mov	x0, x20
	bl	_mutex_lock_interruptible
	cbnz	w0, LBB0_5
; %bb.7:
	add	x0, x20, #4
	bl	_atomic_inc
	mov	x0, x20
	bl	_mutex_unlock
	mov	x0, x19
	bl	_check_disk_change
	mov	w0, #0
	b	LBB0_5
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_md_misc_wq,4,2                 ; @md_misc_wq
	.comm	_ERESTARTSYS,4,2                ; @ERESTARTSYS
	.no_dead_strip	_md_open
.subsections_via_symbols
