	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vhba_modprobe                  ## -- Begin function vhba_modprobe
	.p2align	4, 0x90
_vhba_modprobe:                         ## @vhba_modprobe
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpl	$128, %esi
	je	LBB0_4
## %bb.1:
	cmpl	$129, %esi
	jne	LBB0_8
## %bb.2:
	movq	_M_DEVBUF@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	_M_WAITOK@GOTPCREL(%rip), %rax
	movq	_M_ZERO@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movl	$12, %edi
	callq	_malloc
	movq	_vhba@GOTPCREL(%rip), %r12
	movq	%rax, (%r12)
	movq	_MTX_DEF@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%rax, %rdi
	xorl	%edx, %edx
	callq	_mtx_init
	movq	(%r12), %rdi
	callq	_vhba_attach
	testl	%eax, %eax
	je	LBB0_9
## %bb.3:
	movl	%eax, %r14d
	movq	(%r12), %rdi
	callq	_mtx_destroy
	movq	(%r12), %rdi
	movl	(%r15), %esi
	callq	_free
	movl	%r14d, %ebx
	jmp	LBB0_9
LBB0_4:
	movq	_vhba@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	callq	_mtx_lock
	movq	(%r14), %rdi
	addq	$8, %rdi
	callq	_TAILQ_FIRST
	testl	%eax, %eax
	jne	LBB0_6
## %bb.5:
	movq	(%r14), %rdi
	addq	$4, %rdi
	callq	_TAILQ_FIRST
	testl	%eax, %eax
	je	LBB0_7
LBB0_6:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	(%r14), %rdi
	callq	_mtx_unlock
	jmp	LBB0_9
LBB0_8:
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_9:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	(%r14), %rdi
	callq	_vhba_detach
	movq	(%r14), %rdi
	callq	_mtx_unlock
	movq	(%r14), %rdi
	callq	_mtx_destroy
	movq	(%r14), %rdi
	movq	_M_DEVBUF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_free
	xorl	%ebx, %ebx
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_M_DEVBUF,4,2                   ## @M_DEVBUF
	.comm	_M_WAITOK,4,2                   ## @M_WAITOK
	.comm	_M_ZERO,4,2                     ## @M_ZERO
	.comm	_vhba,8,3                       ## @vhba
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"vhba"

	.comm	_MTX_DEF,4,2                    ## @MTX_DEF
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vhba_modprobe                  ; -- Begin function vhba_modprobe
	.p2align	2
_vhba_modprobe:                         ; @vhba_modprobe
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	cmp	w1, #128
	b.eq	LBB0_4
; %bb.1:
	cmp	w1, #129
	b.ne	LBB0_7
; %bb.2:
Lloh0:
	adrp	x20, _M_DEVBUF@GOTPAGE
Lloh1:
	ldr	x20, [x20, _M_DEVBUF@GOTPAGEOFF]
Lloh2:
	adrp	x8, _M_WAITOK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _M_WAITOK@GOTPAGEOFF]
	ldr	w1, [x20]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _M_ZERO@GOTPAGE
Lloh6:
	ldr	x9, [x9, _M_ZERO@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	w0, #12
	bl	_malloc
Lloh8:
	adrp	x21, _vhba@GOTPAGE
Lloh9:
	ldr	x21, [x21, _vhba@GOTPAGEOFF]
	str	x0, [x21]
Lloh10:
	adrp	x8, _MTX_DEF@GOTPAGE
Lloh11:
	ldr	x8, [x8, _MTX_DEF@GOTPAGEOFF]
Lloh12:
	ldr	w3, [x8]
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, #0
	bl	_mtx_init
	ldr	x0, [x21]
	bl	_vhba_attach
	mov	x19, x0
	cbz	w0, LBB0_8
; %bb.3:
	ldr	x0, [x21]
	bl	_mtx_destroy
	ldr	x0, [x21]
	ldr	w1, [x20]
	bl	_free
	b	LBB0_8
LBB0_4:
Lloh15:
	adrp	x20, _vhba@GOTPAGE
Lloh16:
	ldr	x20, [x20, _vhba@GOTPAGEOFF]
	ldr	x0, [x20]
	bl	_mtx_lock
	ldr	x8, [x20]
	add	x0, x8, #8
	bl	_TAILQ_FIRST
	cbnz	w0, LBB0_6
; %bb.5:
	ldr	x8, [x20]
	add	x0, x8, #4
	bl	_TAILQ_FIRST
	cbz	w0, LBB0_9
LBB0_6:
Lloh17:
	adrp	x8, _EBUSY@GOTPAGE
Lloh18:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh19:
	ldr	w19, [x8]
	ldr	x0, [x20]
	bl	_mtx_unlock
	b	LBB0_8
LBB0_7:
Lloh20:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh21:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
Lloh22:
	ldr	w19, [x8]
LBB0_8:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_9:
	ldr	x0, [x20]
	bl	_vhba_detach
	ldr	x0, [x20]
	bl	_mtx_unlock
	ldr	x0, [x20]
	bl	_mtx_destroy
	ldr	x0, [x20]
Lloh23:
	adrp	x8, _M_DEVBUF@GOTPAGE
Lloh24:
	ldr	x8, [x8, _M_DEVBUF@GOTPAGEOFF]
Lloh25:
	ldr	w1, [x8]
	bl	_free
	mov	w19, #0
	b	LBB0_8
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_M_DEVBUF,4,2                   ; @M_DEVBUF
	.comm	_M_WAITOK,4,2                   ; @M_WAITOK
	.comm	_M_ZERO,4,2                     ; @M_ZERO
	.comm	_vhba,8,3                       ; @vhba
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"vhba"

	.comm	_MTX_DEF,4,2                    ; @MTX_DEF
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
.subsections_via_symbols
