	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function __sdhci_execute_tuning
___sdhci_execute_tuning:                ## @__sdhci_execute_tuning
	.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
	movq	%rdi, %r15
	cmpl	$0, (%rdi)
	jle	LBB0_9
## %bb.1:
	movl	%esi, %r14d
	xorl	%ebx, %ebx
	movq	_SDHCI_HOST_CONTROL2@GOTPCREL(%rip), %r12
	movq	_SDHCI_CTRL_EXEC_TUNING@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_sdhci_send_tuning
	cmpl	$0, 20(%r15)
	je	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	8(%r15), %rdi
	testq	%rdi, %rdi
	jle	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_3 Depth=1
	callq	_mdelay
LBB0_7:                                 ##   in Loop: Header=BB0_3 Depth=1
	movl	(%r12), %esi
	movq	%r15, %rdi
	callq	_sdhci_readw
	testl	%eax, (%r13)
	je	LBB0_8
## %bb.2:                               ##   in Loop: Header=BB0_3 Depth=1
	incl	%ebx
	cmpl	(%r15), %ebx
	jl	LBB0_3
	jmp	LBB0_9
LBB0_4:
	movl	16(%r15), %edi
	callq	_mmc_hostname
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_pr_info
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_sdhci_abort_tuning
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rcx
	jmp	LBB0_10
LBB0_8:
	movl	%eax, %ecx
	movq	_SDHCI_CTRL_TUNED_CLK@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	testl	%ecx, (%rdx)
	jne	LBB0_11
LBB0_9:
	movl	16(%r15), %edi
	callq	_mmc_hostname
	leaq	L_.str.1(%rip), %rdi
	movl	%eax, %esi
	callq	_pr_info
	movq	%r15, %rdi
	callq	_sdhci_reset_tuning
	movq	_EAGAIN@GOTPCREL(%rip), %rcx
LBB0_10:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: Tuning timeout, falling back to fixed sampling clock\n"

	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.comm	_SDHCI_HOST_CONTROL2,4,2        ## @SDHCI_HOST_CONTROL2
	.comm	_SDHCI_CTRL_EXEC_TUNING,4,2     ## @SDHCI_CTRL_EXEC_TUNING
	.comm	_SDHCI_CTRL_TUNED_CLK,4,2       ## @SDHCI_CTRL_TUNED_CLK
L_.str.1:                               ## @.str.1
	.asciz	"%s: Tuning failed, falling back to fixed sampling clock\n"

	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.no_dead_strip	___sdhci_execute_tuning
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function __sdhci_execute_tuning
___sdhci_execute_tuning:                ; @__sdhci_execute_tuning
	.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
	mov	x19, x0
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_10
; %bb.1:
	mov	x20, x1
	mov	w21, #0
Lloh0:
	adrp	x22, _SDHCI_HOST_CONTROL2@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SDHCI_HOST_CONTROL2@GOTPAGEOFF]
Lloh2:
	adrp	x23, _SDHCI_CTRL_EXEC_TUNING@GOTPAGE
Lloh3:
	ldr	x23, [x23, _SDHCI_CTRL_EXEC_TUNING@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	mov	x1, x20
	bl	_sdhci_send_tuning
	ldr	w8, [x19, #20]
	cbz	w8, LBB0_7
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x0, [x19, #8]
	cmp	x0, #1
	b.lt	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	bl	_mdelay
LBB0_5:                                 ;   in Loop: Header=BB0_2 Depth=1
	ldr	w1, [x22]
	mov	x0, x19
	bl	_sdhci_readw
	ldr	w8, [x23]
	tst	w8, w0
	b.eq	LBB0_8
; %bb.6:                                ;   in Loop: Header=BB0_2 Depth=1
	add	w21, w21, #1
	ldr	w8, [x19]
	cmp	w21, w8
	b.lt	LBB0_2
	b	LBB0_10
LBB0_7:
	ldr	w0, [x19, #16]
	bl	_mmc_hostname
	mov	x1, x0
Lloh4:
	adrp	x0, l_.str@PAGE
Lloh5:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_info
	mov	x0, x19
	mov	x1, x20
	bl	_sdhci_abort_tuning
Lloh6:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
	b	LBB0_11
LBB0_8:
Lloh8:
	adrp	x8, _SDHCI_CTRL_TUNED_CLK@GOTPAGE
Lloh9:
	ldr	x8, [x8, _SDHCI_CTRL_TUNED_CLK@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_10
; %bb.9:
	mov	w0, #0
	b	LBB0_12
LBB0_10:
	ldr	w0, [x19, #16]
	bl	_mmc_hostname
	mov	x1, x0
Lloh11:
	adrp	x0, l_.str.1@PAGE
Lloh12:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pr_info
	mov	x0, x19
	bl	_sdhci_reset_tuning
Lloh13:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
LBB0_11:
	ldr	w8, [x8]
	neg	w0, w8
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 AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: Tuning timeout, falling back to fixed sampling clock\n"

	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.comm	_SDHCI_HOST_CONTROL2,4,2        ; @SDHCI_HOST_CONTROL2
	.comm	_SDHCI_CTRL_EXEC_TUNING,4,2     ; @SDHCI_CTRL_EXEC_TUNING
	.comm	_SDHCI_CTRL_TUNED_CLK,4,2       ; @SDHCI_CTRL_TUNED_CLK
l_.str.1:                               ; @.str.1
	.asciz	"%s: Tuning failed, falling back to fixed sampling clock\n"

	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.no_dead_strip	___sdhci_execute_tuning
.subsections_via_symbols
