	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function do_fd_action
_do_fd_action:                          ## @do_fd_action
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %ebx
	leaq	L_.str(%rip), %rdi
	callq	_DPRINT
	movq	_UseTrackbuffer@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_9
## %bb.1:
	movq	_IsFormatting@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jne	LBB0_9
## %bb.2:
	movq	_ReqSide@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_ReqTrack@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%ebx, %edi
	callq	_IS_BUFFERED
	testq	%rax, %rax
	je	LBB0_9
## %bb.3:
	movq	_ReqData@GOTPCREL(%rip), %r12
	movq	_ReqCnt@GOTPCREL(%rip), %r13
	movq	_fd_request@GOTPCREL(%rip), %r15
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	_ReqCmd@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_READ@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_8
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	_ReqSector@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_SECTOR_BUFFER
	movl	(%r12), %esi
	movl	%eax, %edi
	callq	_copy_buffer
	movq	(%r13), %r14
	incq	%r14
	movq	%r14, (%r13)
	movl	(%r15), %edi
	callq	_blk_rq_cur_sectors
	cmpq	%rax, %r14
	jge	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	%ebx, %edi
	callq	_setup_req_params
	movq	_ReqSide@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_ReqTrack@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%ebx, %edi
	callq	_IS_BUFFERED
	testq	%rax, %rax
	jne	LBB0_4
	jmp	LBB0_9
LBB0_8:
	movl	(%r12), %r14d
	movq	_ReqSector@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_SECTOR_BUFFER
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_copy_buffer
LBB0_9:
	movq	_SelectedDrive@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	je	LBB0_11
## %bb.10:
	movl	%ebx, %edi
	callq	_fd_select_drive
LBB0_11:
	movq	_UD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cmpl	$-1, %eax
	je	LBB0_15
## %bb.12:
	movq	_ReqTrack@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	_UDT@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movb	(%rcx), %cl
	shll	%cl, %edx
	cmpl	%edx, %eax
	jne	LBB0_16
## %bb.13:
	movq	_IsFormatting@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_14
## %bb.17:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fd_writetrack                  ## TAILCALL
LBB0_15:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fd_calibrate                   ## TAILCALL
LBB0_16:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fd_seek                        ## TAILCALL
LBB0_7:
	xorl	%edi, %edi
	callq	_fd_end_request_cur
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_redo_fd_request                ## TAILCALL
LBB0_14:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fd_rwsec                       ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"do_fd_action\n"

	.comm	_UseTrackbuffer,8,3             ## @UseTrackbuffer
	.comm	_IsFormatting,8,3               ## @IsFormatting
	.comm	_ReqSide,4,2                    ## @ReqSide
	.comm	_ReqTrack,4,2                   ## @ReqTrack
	.comm	_ReqCmd,8,3                     ## @ReqCmd
	.comm	_READ,8,3                       ## @READ
	.comm	_ReqSector,4,2                  ## @ReqSector
	.comm	_ReqData,4,2                    ## @ReqData
	.comm	_ReqCnt,8,3                     ## @ReqCnt
	.comm	_fd_request,4,2                 ## @fd_request
	.comm	_SelectedDrive,4,2              ## @SelectedDrive
	.comm	_UD,4,2                         ## @UD
	.comm	_UDT,8,3                        ## @UDT
	.no_dead_strip	_do_fd_action
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function do_fd_action
_do_fd_action:                          ; @do_fd_action
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DPRINT
Lloh2:
	adrp	x8, _UseTrackbuffer@GOTPAGE
Lloh3:
	ldr	x8, [x8, _UseTrackbuffer@GOTPAGEOFF]
Lloh4:
	adrp	x9, _IsFormatting@GOTPAGE
Lloh5:
	ldr	x9, [x9, _IsFormatting@GOTPAGEOFF]
Lloh6:
	ldr	x8, [x8]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, #0
	ccmp	x9, #0, #0, ne
Lloh8:
	adrp	x22, _ReqTrack@GOTPAGE
Lloh9:
	ldr	x22, [x22, _ReqTrack@GOTPAGEOFF]
	b.ne	LBB0_7
; %bb.1:
Lloh10:
	adrp	x20, _ReqSide@GOTPAGE
Lloh11:
	ldr	x20, [x20, _ReqSide@GOTPAGEOFF]
	ldr	w1, [x20]
	ldr	w2, [x22]
	mov	x0, x19
	bl	_IS_BUFFERED
	cbz	x0, LBB0_7
; %bb.2:
Lloh12:
	adrp	x24, _ReqCmd@GOTPAGE
Lloh13:
	ldr	x24, [x24, _ReqCmd@GOTPAGEOFF]
Lloh14:
	adrp	x25, _READ@GOTPAGE
Lloh15:
	ldr	x25, [x25, _READ@GOTPAGEOFF]
Lloh16:
	adrp	x23, _ReqSector@GOTPAGE
Lloh17:
	ldr	x23, [x23, _ReqSector@GOTPAGEOFF]
Lloh18:
	adrp	x26, _ReqData@GOTPAGE
Lloh19:
	ldr	x26, [x26, _ReqData@GOTPAGEOFF]
Lloh20:
	adrp	x27, _ReqCnt@GOTPAGE
Lloh21:
	ldr	x27, [x27, _ReqCnt@GOTPAGEOFF]
Lloh22:
	adrp	x28, _fd_request@GOTPAGE
Lloh23:
	ldr	x28, [x28, _fd_request@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x24]
	ldr	x9, [x25]
	cmp	x8, x9
	b.ne	LBB0_6
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w0, [x23]
	bl	_SECTOR_BUFFER
	ldr	w1, [x26]
	bl	_copy_buffer
	ldr	x8, [x27]
	add	x21, x8, #1
	str	x21, [x27]
	ldr	w0, [x28]
	bl	_blk_rq_cur_sectors
	cmp	x21, x0
	b.ge	LBB0_15
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x19
	bl	_setup_req_params
	ldr	w1, [x20]
	ldr	w2, [x22]
	mov	x0, x19
	bl	_IS_BUFFERED
	cbnz	x0, LBB0_3
	b	LBB0_7
LBB0_6:
	ldr	w20, [x26]
	ldr	w0, [x23]
	bl	_SECTOR_BUFFER
	mov	x1, x0
	mov	x0, x20
	bl	_copy_buffer
LBB0_7:
Lloh24:
	adrp	x8, _SelectedDrive@GOTPAGE
Lloh25:
	ldr	x8, [x8, _SelectedDrive@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	cmp	w8, w19
	b.eq	LBB0_9
; %bb.8:
	mov	x0, x19
	bl	_fd_select_drive
LBB0_9:
Lloh27:
	adrp	x8, _UD@GOTPAGE
Lloh28:
	ldr	x8, [x8, _UD@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	cmn	w8, #1
	b.eq	LBB0_13
; %bb.10:
	ldr	w9, [x22]
Lloh30:
	adrp	x10, _UDT@GOTPAGE
Lloh31:
	ldr	x10, [x10, _UDT@GOTPAGEOFF]
Lloh32:
	ldr	x10, [x10]
	ldr	w10, [x10]
	lsl	w9, w9, w10
	cmp	w8, w9
	b.ne	LBB0_14
; %bb.11:
Lloh33:
	adrp	x8, _IsFormatting@GOTPAGE
Lloh34:
	ldr	x8, [x8, _IsFormatting@GOTPAGEOFF]
Lloh35:
	ldr	x8, [x8]
	cbz	x8, LBB0_16
; %bb.12:
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_fd_writetrack
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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_fd_calibrate
LBB0_14:
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_fd_seek
LBB0_15:
	mov	w0, #0
	bl	_fd_end_request_cur
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_redo_fd_request
LBB0_16:
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_fd_rwsec
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh6
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"do_fd_action\n"

	.comm	_UseTrackbuffer,8,3             ; @UseTrackbuffer
	.comm	_IsFormatting,8,3               ; @IsFormatting
	.comm	_ReqSide,4,2                    ; @ReqSide
	.comm	_ReqTrack,4,2                   ; @ReqTrack
	.comm	_ReqCmd,8,3                     ; @ReqCmd
	.comm	_READ,8,3                       ; @READ
	.comm	_ReqSector,4,2                  ; @ReqSector
	.comm	_ReqData,4,2                    ; @ReqData
	.comm	_ReqCnt,8,3                     ; @ReqCnt
	.comm	_fd_request,4,2                 ; @fd_request
	.comm	_SelectedDrive,4,2              ; @SelectedDrive
	.comm	_UD,4,2                         ; @UD
	.comm	_UDT,8,3                        ; @UDT
	.no_dead_strip	_do_fd_action
.subsections_via_symbols
