	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function freedev
_freedev:                               ## @freedev
	.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
	movq	%rdi, %r15
	leaq	8(%rdi), %r14
	movq	%r14, %rdi
	callq	_spin_lock_irqsave
	movl	(%r15), %eax
	movq	_DEVFL_TKILL@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_11
## %bb.1:
	movq	_DEVFL_FREEING@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%eax, %ecx
	jne	LBB0_11
## %bb.2:
	orl	%eax, %ecx
	movl	%ecx, (%r15)
	movq	%r14, %rdi
	callq	_spin_unlock_irqrestore
	leaq	48(%r15), %rdi
	callq	_del_timer_sync
	cmpq	$0, 40(%r15)
	je	LBB0_4
## %bb.3:
	movq	%r15, %rdi
	callq	_aoedisk_rm_sysfs
	movq	40(%r15), %rdi
	callq	_del_gendisk
	movq	40(%r15), %rdi
	callq	_put_disk
	movl	32(%r15), %edi
	callq	_blk_cleanup_queue
LBB0_4:
	movslq	4(%r15), %rax
	testq	%rax, %rax
	jle	LBB0_8
## %bb.5:
	movq	24(%r15), %rbx
	leaq	(%rbx,%rax,8), %r12
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rbx), %rsi
	testq	%rsi, %rsi
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	%r15, %rdi
	callq	_freetgt
	addq	$8, %rbx
	cmpq	%r12, %rbx
	jb	LBB0_6
LBB0_8:
	movq	16(%r15), %rdi
	testq	%rdi, %rdi
	je	LBB0_10
## %bb.9:
	callq	_mempool_destroy
LBB0_10:
	movq	%r15, %rdi
	callq	_skbpoolfree
	movl	12(%r15), %edi
	callq	_minor_free
	movq	%r14, %rdi
	callq	_spin_lock_irqsave
	movq	_DEVFL_FREED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%r15)
LBB0_11:
	movq	%r14, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_irqrestore         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_DEVFL_TKILL,4,2                ## @DEVFL_TKILL
	.comm	_DEVFL_FREEING,4,2              ## @DEVFL_FREEING
	.comm	_DEVFL_FREED,4,2                ## @DEVFL_FREED
	.no_dead_strip	_freedev
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function freedev
_freedev:                               ; @freedev
	.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
	mov	x20, x0
	add	x19, x0, #8
	mov	x0, x19
	bl	_spin_lock_irqsave
	ldr	w8, [x20]
Lloh0:
	adrp	x9, _DEVFL_TKILL@GOTPAGE
Lloh1:
	ldr	x9, [x9, _DEVFL_TKILL@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_11
; %bb.1:
Lloh3:
	adrp	x9, _DEVFL_FREEING@GOTPAGE
Lloh4:
	ldr	x9, [x9, _DEVFL_FREEING@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_11
; %bb.2:
	orr	w8, w9, w8
	str	w8, [x20]
	mov	x0, x19
	bl	_spin_unlock_irqrestore
	add	x0, x20, #48
	bl	_del_timer_sync
	ldr	x8, [x20, #40]
	cbz	x8, LBB0_4
; %bb.3:
	mov	x0, x20
	bl	_aoedisk_rm_sysfs
	ldr	x0, [x20, #40]
	bl	_del_gendisk
	ldr	x0, [x20, #40]
	bl	_put_disk
	ldr	w0, [x20, #32]
	bl	_blk_cleanup_queue
LBB0_4:
	ldrsw	x8, [x20, #4]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.5:
	ldr	x21, [x20, #24]
	add	x22, x21, x8, lsl #3
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x1, [x21]
	cbz	x1, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x20
	bl	_freetgt
	add	x21, x21, #8
	cmp	x21, x22
	b.lo	LBB0_6
LBB0_8:
	ldr	x0, [x20, #16]
	cbz	x0, LBB0_10
; %bb.9:
	bl	_mempool_destroy
LBB0_10:
	mov	x0, x20
	bl	_skbpoolfree
	ldr	w0, [x20, #12]
	bl	_minor_free
	mov	x0, x19
	bl	_spin_lock_irqsave
Lloh6:
	adrp	x8, _DEVFL_FREED@GOTPAGE
Lloh7:
	ldr	x8, [x8, _DEVFL_FREED@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	ldr	w9, [x20]
	orr	w8, w9, w8
	str	w8, [x20]
LBB0_11:
	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
	b	_spin_unlock_irqrestore
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_DEVFL_TKILL,4,2                ; @DEVFL_TKILL
	.comm	_DEVFL_FREEING,4,2              ; @DEVFL_FREEING
	.comm	_DEVFL_FREED,4,2                ; @DEVFL_FREED
	.no_dead_strip	_freedev
.subsections_via_symbols
