	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sdhci_transfer_pio
_sdhci_transfer_pio:                    ## @sdhci_transfer_pio
	.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
	cmpq	$0, (%rdi)
	je	LBB0_15
## %bb.1:
	movq	%rdi, %rbx
	movq	16(%rdi), %rax
	movq	_MMC_DATA_READ@GOTPCREL(%rip), %r14
	movl	(%r14), %ecx
	testl	%ecx, (%rax)
	jne	LBB0_2
## %bb.3:
	movq	_SDHCI_SPACE_AVAILABLE@GOTPCREL(%rip), %rcx
	jmp	LBB0_4
LBB0_15:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movq	_SDHCI_DATA_AVAILABLE@GOTPCREL(%rip), %rcx
LBB0_4:
	movl	(%rcx), %r15d
	movq	_SDHCI_QUIRK_BROKEN_SMALL_PIO@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, 8(%rbx)
	je	LBB0_6
## %bb.5:
	cmpl	$1, 4(%rax)
	movl	$-1, %eax
	cmovel	%eax, %r15d
LBB0_6:
	movq	_SDHCI_PRESENT_STATE@GOTPCREL(%rip), %r12
	movq	_SDHCI_QUIRK_PIO_NEEDS_DELAY@GOTPCREL(%rip), %r13
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_7 Depth=1
	movq	%rbx, %rdi
	callq	_sdhci_read_block_pio
	decq	(%rbx)
	je	LBB0_14
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_sdhci_readl
	testl	%r15d, %eax
	je	LBB0_14
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	(%r13), %eax
	testl	%eax, 8(%rbx)
	je	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	$100, %edi
	callq	_udelay
LBB0_10:                                ##   in Loop: Header=BB0_7 Depth=1
	movq	16(%rbx), %rax
	movl	(%r14), %ecx
	testl	%ecx, (%rax)
	jne	LBB0_11
## %bb.12:                              ##   in Loop: Header=BB0_7 Depth=1
	movq	%rbx, %rdi
	callq	_sdhci_write_block_pio
	decq	(%rbx)
	jne	LBB0_7
LBB0_14:
	leaq	L_.str(%rip), %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DBG                            ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MMC_DATA_READ,4,2              ## @MMC_DATA_READ
	.comm	_SDHCI_DATA_AVAILABLE,4,2       ## @SDHCI_DATA_AVAILABLE
	.comm	_SDHCI_SPACE_AVAILABLE,4,2      ## @SDHCI_SPACE_AVAILABLE
	.comm	_SDHCI_QUIRK_BROKEN_SMALL_PIO,4,2 ## @SDHCI_QUIRK_BROKEN_SMALL_PIO
	.comm	_SDHCI_PRESENT_STATE,4,2        ## @SDHCI_PRESENT_STATE
	.comm	_SDHCI_QUIRK_PIO_NEEDS_DELAY,4,2 ## @SDHCI_QUIRK_PIO_NEEDS_DELAY
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"PIO transfer complete.\n"

	.no_dead_strip	_sdhci_transfer_pio
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sdhci_transfer_pio
_sdhci_transfer_pio:                    ; @sdhci_transfer_pio
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	x8, [x0]
	cbz	x8, LBB0_12
; %bb.1:
	mov	x19, x0
	ldr	x8, [x0, #16]
	ldr	w9, [x8]
Lloh0:
	adrp	x20, _MMC_DATA_READ@GOTPAGE
Lloh1:
	ldr	x20, [x20, _MMC_DATA_READ@GOTPAGEOFF]
	ldr	w10, [x20]
Lloh2:
	adrp	x11, _SDHCI_SPACE_AVAILABLE@GOTPAGE
Lloh3:
	ldr	x11, [x11, _SDHCI_SPACE_AVAILABLE@GOTPAGEOFF]
Lloh4:
	adrp	x12, _SDHCI_DATA_AVAILABLE@GOTPAGE
Lloh5:
	ldr	x12, [x12, _SDHCI_DATA_AVAILABLE@GOTPAGEOFF]
	tst	w10, w9
	csel	x9, x11, x12, eq
	ldr	w21, [x9]
	ldr	w9, [x0, #8]
Lloh6:
	adrp	x10, _SDHCI_QUIRK_BROKEN_SMALL_PIO@GOTPAGE
Lloh7:
	ldr	x10, [x10, _SDHCI_QUIRK_BROKEN_SMALL_PIO@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_3
; %bb.2:
	ldr	w8, [x8, #4]
	cmp	w8, #1
	csinv	w21, w21, wzr, ne
LBB0_3:
Lloh9:
	adrp	x22, _SDHCI_PRESENT_STATE@GOTPAGE
Lloh10:
	ldr	x22, [x22, _SDHCI_PRESENT_STATE@GOTPAGEOFF]
Lloh11:
	adrp	x23, _SDHCI_QUIRK_PIO_NEEDS_DELAY@GOTPAGE
Lloh12:
	ldr	x23, [x23, _SDHCI_QUIRK_PIO_NEEDS_DELAY@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	bl	_sdhci_read_block_pio
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [x19]
	subs	x8, x8, #1
	str	x8, [x19]
	b.eq	LBB0_11
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x22]
	mov	x0, x19
	bl	_sdhci_readl
	tst	w0, w21
	b.eq	LBB0_11
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [x19, #8]
	ldr	w9, [x23]
	tst	w9, w8
	b.eq	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	w0, #100
	bl	_udelay
LBB0_9:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [x19, #16]
	ldr	w8, [x8]
	ldr	w9, [x20]
	mov	x0, x19
	tst	w9, w8
	b.ne	LBB0_4
; %bb.10:                               ;   in Loop: Header=BB0_6 Depth=1
	bl	_sdhci_write_block_pio
	b	LBB0_5
LBB0_11:
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_DBG
LBB0_12:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_MMC_DATA_READ,4,2              ; @MMC_DATA_READ
	.comm	_SDHCI_DATA_AVAILABLE,4,2       ; @SDHCI_DATA_AVAILABLE
	.comm	_SDHCI_SPACE_AVAILABLE,4,2      ; @SDHCI_SPACE_AVAILABLE
	.comm	_SDHCI_QUIRK_BROKEN_SMALL_PIO,4,2 ; @SDHCI_QUIRK_BROKEN_SMALL_PIO
	.comm	_SDHCI_PRESENT_STATE,4,2        ; @SDHCI_PRESENT_STATE
	.comm	_SDHCI_QUIRK_PIO_NEEDS_DELAY,4,2 ; @SDHCI_QUIRK_PIO_NEEDS_DELAY
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"PIO transfer complete.\n"

	.no_dead_strip	_sdhci_transfer_pio
.subsections_via_symbols
