	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function command_do
_command_do:                            ## @command_do
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r12
	movq	_DBG_FLOW@GOTPCREL(%rip), %rax
	movq	_DBG_CMD@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	orl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r12, %rdx
	xorl	%eax, %eax
	callq	_PRINTD
	movq	_dead@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r12, %rsi
	callq	_test_bit
	testq	%rax, %rax
	jne	LBB0_12
## %bb.1:
	leaq	32(%r12), %rbx
	movq	%rbx, %rdi
	callq	_spin_lock
	movq	8(%r12), %rax
	cmpq	16(%r12), %rax
	jge	LBB0_11
## %bb.2:
	movq	56(%r12), %r15
	movq	_DBG_CMD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_PRINTD
	movq	%r14, %rdi
	callq	_dump_command
	movq	56(%r12), %rax
	movq	(%r14), %rcx
	movq	%rcx, (%rax)
	incq	8(%r12)
	movq	56(%r12), %rdi
	movl	44(%r12), %esi
	movl	40(%r12), %edx
	callq	_NEXTQ
	movq	%rax, 56(%r12)
	movq	_amb_mem@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_mb@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_offsetof
	movl	%eax, %r13d
	movq	56(%r12), %rdi
	callq	_virt_to_bus
	movq	%r12, %rdi
	movl	%r13d, %esi
	movl	%eax, %edx
	callq	_wr_mem
	movq	8(%r12), %rax
	cmpq	24(%r12), %rax
	jle	LBB0_4
## %bb.3:
	movq	%rax, 24(%r12)
LBB0_4:
	movq	%r14, -56(%rbp)                 ## 8-byte Spill
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_spin_unlock
	movq	8(%r12), %rdi
	callq	_msleep
	movq	48(%r12), %rax
	cmpq	%r15, %rax
	movq	_DBG_CMD@GOTPCREL(%rip), %rbx
	je	LBB0_7
## %bb.5:
	leaq	L_.str.2(%rip), %r13
	movq	_TASK_UNINTERRUPTIBLE@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rbx), %edi
	movq	48(%r12), %rdx
	movq	%r13, %rsi
	xorl	%eax, %eax
	callq	_PRINTD
	movl	(%r14), %edi
	callq	_set_current_state
	xorl	%eax, %eax
	callq	_schedule
	movq	48(%r12), %rax
	cmpq	%r15, %rax
	jne	LBB0_6
LBB0_7:
	movq	48(%r12), %rax
	movq	(%rax), %r14
	movq	_SRB_COMPLETE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_be32
	cmpq	%rax, %r14
	je	LBB0_10
## %bb.8:
	leaq	L_.str.3(%rip), %r13
	movq	_TASK_UNINTERRUPTIBLE@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rbx), %edi
	movq	%r13, %rsi
	xorl	%eax, %eax
	callq	_PRINTD
	movl	(%r14), %edi
	callq	_set_current_state
	xorl	%eax, %eax
	callq	_schedule
	movq	48(%r12), %rax
	movq	(%rax), %r15
	movq	_SRB_COMPLETE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_be32
	cmpq	%rax, %r15
	movq	_DBG_CMD@GOTPCREL(%rip), %rbx
	jne	LBB0_9
LBB0_10:
	movl	(%rbx), %edi
	leaq	L_.str.4(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_PRINTD
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	callq	_spin_lock
	decq	8(%r12)
	movq	48(%r12), %rax
	movq	(%rax), %rax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	movq	48(%r12), %rdi
	movl	44(%r12), %esi
	movl	40(%r12), %edx
	callq	_NEXTQ
	movq	%rax, 48(%r12)
	movq	%r14, %rdi
	callq	_spin_unlock
	jmp	LBB0_12
LBB0_11:
	incl	36(%r12)
	movq	%rbx, %rdi
	callq	_spin_unlock
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_12:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DBG_FLOW,4,2                   ## @DBG_FLOW
	.comm	_DBG_CMD,4,2                    ## @DBG_CMD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"command_do %p"

	.comm	_dead,4,2                       ## @dead
L_.str.1:                               ## @.str.1
	.asciz	"command in slot %p"

	.comm	_amb_mem,4,2                    ## @amb_mem
	.comm	_mb,4,2                         ## @mb
L_.str.2:                               ## @.str.2
	.asciz	"wait: command slot (now at %p)"

	.comm	_TASK_UNINTERRUPTIBLE,4,2       ## @TASK_UNINTERRUPTIBLE
	.comm	_SRB_COMPLETE,4,2               ## @SRB_COMPLETE
L_.str.3:                               ## @.str.3
	.asciz	"wait: command slot completion"

L_.str.4:                               ## @.str.4
	.asciz	"command complete"

	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.no_dead_strip	_command_do
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function command_do
_command_do:                            ; @command_do
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _DBG_FLOW@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DBG_FLOW@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x23, _DBG_CMD@GOTPAGE
Lloh4:
	ldr	x23, [x23, _DBG_CMD@GOTPAGEOFF]
	ldr	w9, [x23]
	orr	w0, w9, w8
	str	x19, [sp]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	bl	_PRINTD
Lloh7:
	adrp	x8, _dead@GOTPAGE
Lloh8:
	ldr	x8, [x8, _dead@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_test_bit
	cbz	x0, LBB0_2
; %bb.1:
	mov	w0, #0
	b	LBB0_13
LBB0_2:
	add	x21, x19, #32
	mov	x0, x21
	bl	_spin_lock
	ldp	x8, x9, [x19, #8]
	cmp	x8, x9
	b.ge	LBB0_12
; %bb.3:
	ldr	x24, [x19, #56]
	ldr	w0, [x23]
	str	x24, [sp]
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_PRINTD
	mov	x0, x20
	bl	_dump_command
	ldr	x8, [x19, #56]
	ldr	x9, [x20]
	str	x9, [x8]
	ldr	x8, [x19, #8]
	add	x8, x8, #1
	str	x8, [x19, #8]
	ldr	x0, [x19, #56]
	ldr	w1, [x19, #44]
	ldr	w2, [x19, #40]
	bl	_NEXTQ
	str	x0, [x19, #56]
Lloh12:
	adrp	x8, _amb_mem@GOTPAGE
Lloh13:
	ldr	x8, [x8, _amb_mem@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
Lloh15:
	adrp	x8, _mb@GOTPAGE
Lloh16:
	ldr	x8, [x8, _mb@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	bl	_offsetof
	mov	x22, x0
	ldr	x0, [x19, #56]
	bl	_virt_to_bus
	mov	x2, x0
	mov	x0, x19
	mov	x1, x22
	bl	_wr_mem
	ldr	x8, [x19, #8]
	ldr	x9, [x19, #24]
	cmp	x8, x9
	b.le	LBB0_5
; %bb.4:
	str	x8, [x19, #24]
LBB0_5:
	mov	x0, x21
	bl	_spin_unlock
	ldr	x0, [x19, #8]
	bl	_msleep
	ldr	x8, [x19, #48]
	cmp	x8, x24
	b.eq	LBB0_8
; %bb.6:
Lloh18:
	adrp	x22, l_.str.2@PAGE
Lloh19:
	add	x22, x22, l_.str.2@PAGEOFF
Lloh20:
	adrp	x25, _TASK_UNINTERRUPTIBLE@GOTPAGE
Lloh21:
	ldr	x25, [x25, _TASK_UNINTERRUPTIBLE@GOTPAGEOFF]
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x23]
	ldr	x8, [x19, #48]
	str	x8, [sp]
	mov	x1, x22
	bl	_PRINTD
	ldr	w0, [x25]
	bl	_set_current_state
	bl	_schedule
	ldr	x8, [x19, #48]
	cmp	x8, x24
	b.ne	LBB0_7
LBB0_8:
	ldr	x8, [x19, #48]
	ldr	x22, [x8]
Lloh22:
	adrp	x24, _SRB_COMPLETE@GOTPAGE
Lloh23:
	ldr	x24, [x24, _SRB_COMPLETE@GOTPAGEOFF]
	ldr	w0, [x24]
	bl	_cpu_to_be32
	cmp	x22, x0
	b.eq	LBB0_11
; %bb.9:
Lloh24:
	adrp	x22, l_.str.3@PAGE
Lloh25:
	add	x22, x22, l_.str.3@PAGEOFF
Lloh26:
	adrp	x25, _TASK_UNINTERRUPTIBLE@GOTPAGE
Lloh27:
	ldr	x25, [x25, _TASK_UNINTERRUPTIBLE@GOTPAGEOFF]
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x23]
	mov	x1, x22
	bl	_PRINTD
	ldr	w0, [x25]
	bl	_set_current_state
	bl	_schedule
	ldr	x8, [x19, #48]
	ldr	x26, [x8]
	ldr	w0, [x24]
	bl	_cpu_to_be32
	cmp	x26, x0
	b.ne	LBB0_10
LBB0_11:
	ldr	w0, [x23]
Lloh28:
	adrp	x1, l_.str.4@PAGE
Lloh29:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_PRINTD
	mov	x0, x21
	bl	_spin_lock
	ldr	x8, [x19, #8]
	sub	x8, x8, #1
	str	x8, [x19, #8]
	ldr	x8, [x19, #48]
	ldr	x8, [x8]
	str	x8, [x20]
	ldr	x0, [x19, #48]
	ldr	w1, [x19, #44]
	ldr	w2, [x19, #40]
	bl	_NEXTQ
	str	x0, [x19, #48]
	mov	x0, x21
	bl	_spin_unlock
	mov	w0, #0
	b	LBB0_13
LBB0_12:
	ldr	w8, [x19, #36]
	add	w8, w8, #1
	str	w8, [x19, #36]
	mov	x0, x21
	bl	_spin_unlock
Lloh30:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh31:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_13:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	_DBG_FLOW,4,2                   ; @DBG_FLOW
	.comm	_DBG_CMD,4,2                    ; @DBG_CMD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"command_do %p"

	.comm	_dead,4,2                       ; @dead
l_.str.1:                               ; @.str.1
	.asciz	"command in slot %p"

	.comm	_amb_mem,4,2                    ; @amb_mem
	.comm	_mb,4,2                         ; @mb
l_.str.2:                               ; @.str.2
	.asciz	"wait: command slot (now at %p)"

	.comm	_TASK_UNINTERRUPTIBLE,4,2       ; @TASK_UNINTERRUPTIBLE
	.comm	_SRB_COMPLETE,4,2               ; @SRB_COMPLETE
l_.str.3:                               ; @.str.3
	.asciz	"wait: command slot completion"

l_.str.4:                               ; @.str.4
	.asciz	"command complete"

	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.no_dead_strip	_command_do
.subsections_via_symbols
