	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sdhci_config_dma
_sdhci_config_dma:                      ## @sdhci_config_dma
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	(%rdi), %rax
	movq	_SDHCI_SPEC_200@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jge	LBB0_1
## %bb.11:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	%rdi, %rbx
	movq	_SDHCI_HOST_CONTROL@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	callq	_sdhci_readb
	movq	_SDHCI_CTRL_DMA_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	notl	%esi
	andl	%eax, %esi
	movl	8(%rbx), %eax
	movq	_SDHCI_REQ_USE_DMA@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_10
## %bb.2:
	movq	_SDHCI_USE_ADMA@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, %r15d
	andl	%eax, %r15d
	je	LBB0_4
## %bb.3:
	movq	_SDHCI_CTRL_ADMA32@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r15d
LBB0_4:
	orl	%esi, %r15d
	movq	_SDHCI_USE_64_BIT_DMA@GOTPCREL(%rip), %rdx
	testl	%eax, (%rdx)
	je	LBB0_9
## %bb.5:
	cmpq	$0, 16(%rbx)
	je	LBB0_7
## %bb.6:
	movq	_SDHCI_HOST_CONTROL2@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_sdhci_readw
	movq	_SDHCI_CTRL_64BIT_ADDR@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%r12), %edx
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_sdhci_writew
	jmp	LBB0_9
LBB0_7:
	testl	%eax, %ecx
	je	LBB0_10
## %bb.8:
	movq	_SDHCI_CTRL_ADMA64@GOTPCREL(%rip), %rax
	orl	(%rax), %r15d
LBB0_9:
	movl	%r15d, %esi
LBB0_10:
	movl	(%r14), %edx
	movq	%rbx, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_sdhci_writeb                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SDHCI_SPEC_200,8,3             ## @SDHCI_SPEC_200
	.comm	_SDHCI_HOST_CONTROL,4,2         ## @SDHCI_HOST_CONTROL
	.comm	_SDHCI_CTRL_DMA_MASK,4,2        ## @SDHCI_CTRL_DMA_MASK
	.comm	_SDHCI_REQ_USE_DMA,4,2          ## @SDHCI_REQ_USE_DMA
	.comm	_SDHCI_USE_ADMA,4,2             ## @SDHCI_USE_ADMA
	.comm	_SDHCI_CTRL_ADMA32,4,2          ## @SDHCI_CTRL_ADMA32
	.comm	_SDHCI_USE_64_BIT_DMA,4,2       ## @SDHCI_USE_64_BIT_DMA
	.comm	_SDHCI_HOST_CONTROL2,4,2        ## @SDHCI_HOST_CONTROL2
	.comm	_SDHCI_CTRL_64BIT_ADDR,4,2      ## @SDHCI_CTRL_64BIT_ADDR
	.comm	_SDHCI_CTRL_ADMA64,4,2          ## @SDHCI_CTRL_ADMA64
	.no_dead_strip	_sdhci_config_dma
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sdhci_config_dma
_sdhci_config_dma:                      ; @sdhci_config_dma
	.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
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _SDHCI_SPEC_200@GOTPAGE
Lloh1:
	ldr	x9, [x9, _SDHCI_SPEC_200@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ge	LBB0_2
; %bb.1:
	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
	ret
LBB0_2:
	mov	x19, x0
Lloh3:
	adrp	x20, _SDHCI_HOST_CONTROL@GOTPAGE
Lloh4:
	ldr	x20, [x20, _SDHCI_HOST_CONTROL@GOTPAGEOFF]
	ldr	w1, [x20]
	bl	_sdhci_readb
Lloh5:
	adrp	x8, _SDHCI_CTRL_DMA_MASK@GOTPAGE
Lloh6:
	ldr	x8, [x8, _SDHCI_CTRL_DMA_MASK@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	bic	w1, w0, w8
	ldr	w8, [x19, #8]
Lloh8:
	adrp	x9, _SDHCI_REQ_USE_DMA@GOTPAGE
Lloh9:
	ldr	x9, [x9, _SDHCI_REQ_USE_DMA@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.3:
Lloh11:
	adrp	x9, _SDHCI_USE_ADMA@GOTPAGE
Lloh12:
	ldr	x9, [x9, _SDHCI_USE_ADMA@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	ands	w9, w9, w8
Lloh14:
	adrp	x10, _SDHCI_CTRL_ADMA32@GOTPAGE
Lloh15:
	ldr	x10, [x10, _SDHCI_CTRL_ADMA32@GOTPAGEOFF]
Lloh16:
	ldr	w10, [x10]
	csel	w10, wzr, w10, eq
	orr	w21, w10, w1
Lloh17:
	adrp	x10, _SDHCI_USE_64_BIT_DMA@GOTPAGE
Lloh18:
	ldr	x10, [x10, _SDHCI_USE_64_BIT_DMA@GOTPAGEOFF]
Lloh19:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_6
; %bb.4:
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_8
; %bb.5:
Lloh20:
	adrp	x22, _SDHCI_HOST_CONTROL2@GOTPAGE
Lloh21:
	ldr	x22, [x22, _SDHCI_HOST_CONTROL2@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	bl	_sdhci_readw
Lloh22:
	adrp	x8, _SDHCI_CTRL_64BIT_ADDR@GOTPAGE
Lloh23:
	ldr	x8, [x8, _SDHCI_CTRL_64BIT_ADDR@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	orr	w1, w8, w0
	ldr	w2, [x22]
	mov	x0, x19
	bl	_sdhci_writew
LBB0_6:
	mov	x1, x21
LBB0_7:
	ldr	w2, [x20]
	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	_sdhci_writeb
LBB0_8:
	cbz	w9, LBB0_7
; %bb.9:
Lloh25:
	adrp	x8, _SDHCI_CTRL_ADMA64@GOTPAGE
Lloh26:
	ldr	x8, [x8, _SDHCI_CTRL_ADMA64@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
	orr	w1, w8, w21
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_SDHCI_SPEC_200,8,3             ; @SDHCI_SPEC_200
	.comm	_SDHCI_HOST_CONTROL,4,2         ; @SDHCI_HOST_CONTROL
	.comm	_SDHCI_CTRL_DMA_MASK,4,2        ; @SDHCI_CTRL_DMA_MASK
	.comm	_SDHCI_REQ_USE_DMA,4,2          ; @SDHCI_REQ_USE_DMA
	.comm	_SDHCI_USE_ADMA,4,2             ; @SDHCI_USE_ADMA
	.comm	_SDHCI_CTRL_ADMA32,4,2          ; @SDHCI_CTRL_ADMA32
	.comm	_SDHCI_USE_64_BIT_DMA,4,2       ; @SDHCI_USE_64_BIT_DMA
	.comm	_SDHCI_HOST_CONTROL2,4,2        ; @SDHCI_HOST_CONTROL2
	.comm	_SDHCI_CTRL_64BIT_ADDR,4,2      ; @SDHCI_CTRL_64BIT_ADDR
	.comm	_SDHCI_CTRL_ADMA64,4,2          ; @SDHCI_CTRL_ADMA64
	.no_dead_strip	_sdhci_config_dma
.subsections_via_symbols
