	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function unlock_fdc
_unlock_fdc:                            ## @unlock_fdc
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	_raw_cmd@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movq	_fdc_busy@GOTPCREL(%rip), %rsi
	xorl	%edi, %edi
	callq	_test_bit
	testl	%eax, %eax
	jne	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_DPRINT
LBB0_2:
	movq	_do_floppy@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	testq	%rsi, %rsi
	je	LBB0_4
## %bb.3:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_DPRINT
LBB0_4:
	movq	_FD_COMMAND_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_command_status@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movq	_floppy_lock@GOTPCREL(%rip), %rdi
	callq	_spin_lock_irqsave
	movq	_fd_timeout@GOTPCREL(%rip), %rdi
	callq	_del_timer
	movq	_cont@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movq	_fdc_busy@GOTPCREL(%rip), %rsi
	xorl	%edi, %edi
	callq	_clear_bit
	movq	_current_req@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jne	LBB0_6
## %bb.5:
	movq	_floppy_queue@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_blk_peek_request
	testq	%rax, %rax
	je	LBB0_7
LBB0_6:
	movq	_floppy_queue@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_do_fd_request
LBB0_7:
	movq	_floppy_lock@GOTPCREL(%rip), %rdi
	callq	_spin_unlock_irqrestore
	movq	_fdc_wait@GOTPCREL(%rip), %rdi
	popq	%rbp
	jmp	_wake_up                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_raw_cmd,8,3                    ## @raw_cmd
	.comm	_fdc_busy,4,2                   ## @fdc_busy
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"FDC access conflict!\n"

	.comm	_do_floppy,8,3                  ## @do_floppy
L_.str.1:                               ## @.str.1
	.asciz	"device interrupt still active at FDC release: %p!\n"

	.comm	_FD_COMMAND_NONE,4,2            ## @FD_COMMAND_NONE
	.comm	_command_status,4,2             ## @command_status
	.comm	_floppy_lock,4,2                ## @floppy_lock
	.comm	_fd_timeout,4,2                 ## @fd_timeout
	.comm	_cont,8,3                       ## @cont
	.comm	_current_req,8,3                ## @current_req
	.comm	_floppy_queue,4,2               ## @floppy_queue
	.comm	_fdc_wait,4,2                   ## @fdc_wait
	.no_dead_strip	_unlock_fdc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function unlock_fdc
_unlock_fdc:                            ; @unlock_fdc
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
Lloh0:
	adrp	x8, _raw_cmd@GOTPAGE
Lloh1:
	ldr	x8, [x8, _raw_cmd@GOTPAGEOFF]
Lloh2:
	str	xzr, [x8]
Lloh3:
	adrp	x1, _fdc_busy@GOTPAGE
Lloh4:
	ldr	x1, [x1, _fdc_busy@GOTPAGEOFF]
	mov	w0, #0
	bl	_test_bit
	cbnz	w0, LBB0_2
; %bb.1:
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DPRINT
LBB0_2:
Lloh7:
	adrp	x8, _do_floppy@GOTPAGE
Lloh8:
	ldr	x8, [x8, _do_floppy@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	cbz	x8, LBB0_4
; %bb.3:
	str	x8, [sp]
Lloh10:
	adrp	x0, l_.str.1@PAGE
Lloh11:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DPRINT
LBB0_4:
Lloh12:
	adrp	x8, _FD_COMMAND_NONE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _FD_COMMAND_NONE@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
Lloh15:
	adrp	x9, _command_status@GOTPAGE
Lloh16:
	ldr	x9, [x9, _command_status@GOTPAGEOFF]
Lloh17:
	str	w8, [x9]
Lloh18:
	adrp	x0, _floppy_lock@GOTPAGE
Lloh19:
	ldr	x0, [x0, _floppy_lock@GOTPAGEOFF]
	bl	_spin_lock_irqsave
Lloh20:
	adrp	x0, _fd_timeout@GOTPAGE
Lloh21:
	ldr	x0, [x0, _fd_timeout@GOTPAGEOFF]
	bl	_del_timer
Lloh22:
	adrp	x8, _cont@GOTPAGE
Lloh23:
	ldr	x8, [x8, _cont@GOTPAGEOFF]
Lloh24:
	str	xzr, [x8]
Lloh25:
	adrp	x1, _fdc_busy@GOTPAGE
Lloh26:
	ldr	x1, [x1, _fdc_busy@GOTPAGEOFF]
	mov	w0, #0
	bl	_clear_bit
Lloh27:
	adrp	x8, _current_req@GOTPAGE
Lloh28:
	ldr	x8, [x8, _current_req@GOTPAGEOFF]
Lloh29:
	ldr	x8, [x8]
Lloh30:
	adrp	x19, _floppy_queue@GOTPAGE
Lloh31:
	ldr	x19, [x19, _floppy_queue@GOTPAGEOFF]
	cbnz	x8, LBB0_6
; %bb.5:
	ldr	w0, [x19]
	bl	_blk_peek_request
	cbz	x0, LBB0_7
LBB0_6:
	ldr	w0, [x19]
	bl	_do_fd_request
LBB0_7:
Lloh32:
	adrp	x0, _floppy_lock@GOTPAGE
Lloh33:
	ldr	x0, [x0, _floppy_lock@GOTPAGEOFF]
	bl	_spin_unlock_irqrestore
Lloh34:
	adrp	x0, _fdc_wait@GOTPAGE
Lloh35:
	ldr	x0, [x0, _fdc_wait@GOTPAGEOFF]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	b	_wake_up
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotStr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGotStr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotStr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh34, Lloh35
	.loh AdrpLdrGot	Lloh32, Lloh33
	.cfi_endproc
                                        ; -- End function
	.comm	_raw_cmd,8,3                    ; @raw_cmd
	.comm	_fdc_busy,4,2                   ; @fdc_busy
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"FDC access conflict!\n"

	.comm	_do_floppy,8,3                  ; @do_floppy
l_.str.1:                               ; @.str.1
	.asciz	"device interrupt still active at FDC release: %p!\n"

	.comm	_FD_COMMAND_NONE,4,2            ; @FD_COMMAND_NONE
	.comm	_command_status,4,2             ; @command_status
	.comm	_floppy_lock,4,2                ; @floppy_lock
	.comm	_fd_timeout,4,2                 ; @fd_timeout
	.comm	_cont,8,3                       ; @cont
	.comm	_current_req,8,3                ; @current_req
	.comm	_floppy_queue,4,2               ; @floppy_queue
	.comm	_fdc_wait,4,2                   ; @fdc_wait
	.no_dead_strip	_unlock_fdc
.subsections_via_symbols
