	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pdc202xx_dma_end
_pdc202xx_dma_end:                      ## @pdc202xx_dma_end
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %rax
	movq	_ide_disk@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	movq	_IDE_DFLAG_LBA48@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 8(%r14)
	je	LBB0_3
LBB0_2:
	movq	24(%r14), %r15
	movslq	(%r15), %rbx
	xorl	%eax, %eax
	cmpq	$0, 8(%r15)
	setne	%al
	leaq	(%rbx,%rax,4), %rsi
	addq	$16, %rsi
	xorl	%edi, %edi
	callq	_outl
	incq	%rbx
	movq	%rbx, %rdi
	callq	_inb
	cmpq	$0, 8(%r15)
	movl	$-3, %ecx
	movl	$-9, %edi
	cmovel	%ecx, %edi
	andl	%eax, %edi
	movq	%rbx, %rsi
	callq	_outb
LBB0_3:
	movq	16(%r14), %rax
	movq	_XFER_UDMA_2@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jle	LBB0_5
## %bb.4:
	movq	24(%r14), %rdi
	callq	_pdc_old_disable_66MHz_clock
LBB0_5:
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ide_dma_end                    ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ide_disk,8,3                   ## @ide_disk
	.comm	_IDE_DFLAG_LBA48,4,2            ## @IDE_DFLAG_LBA48
	.comm	_XFER_UDMA_2,8,3                ## @XFER_UDMA_2
	.no_dead_strip	_pdc202xx_dma_end
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pdc202xx_dma_end
_pdc202xx_dma_end:                      ; @pdc202xx_dma_end
	.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	x19, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _ide_disk@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ide_disk@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
	ldr	w8, [x19, #8]
Lloh3:
	adrp	x9, _IDE_DFLAG_LBA48@GOTPAGE
Lloh4:
	ldr	x9, [x9, _IDE_DFLAG_LBA48@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_3
LBB0_2:
	ldr	x21, [x19, #24]
	ldrsw	x20, [x21]
	ldr	x8, [x21, #8]
	mov	w9, #36
	mov	w10, #32
	cmp	x8, #0
	csel	x8, x10, x9, eq
	add	x8, x20, x8
	sub	x1, x8, #16
	mov	w0, #0
	bl	_outl
	add	x20, x20, #1
	mov	x0, x20
	bl	_inb
	ldr	x8, [x21, #8]
	cmp	x8, #0
	mov	w8, #-9
	mov	w9, #-3
	csel	w8, w9, w8, eq
	and	w0, w8, w0
	mov	x1, x20
	bl	_outb
LBB0_3:
	ldr	x8, [x19, #16]
Lloh6:
	adrp	x9, _XFER_UDMA_2@GOTPAGE
Lloh7:
	ldr	x9, [x9, _XFER_UDMA_2@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	b.le	LBB0_5
; %bb.4:
	ldr	x0, [x19, #24]
	bl	_pdc_old_disable_66MHz_clock
LBB0_5:
	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	_ide_dma_end
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_ide_disk,8,3                   ; @ide_disk
	.comm	_IDE_DFLAG_LBA48,4,2            ; @IDE_DFLAG_LBA48
	.comm	_XFER_UDMA_2,8,3                ; @XFER_UDMA_2
	.no_dead_strip	_pdc202xx_dma_end
.subsections_via_symbols
