	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dw_mci_switch_voltage
_dw_mci_switch_voltage:                 ## @dw_mci_switch_voltage
	.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	%rsi, %r15
	movq	%rdi, %r14
	callq	_mmc_priv
	movq	8(%rax), %r12
	movq	(%r12), %rdx
	movq	_SDMMC_UHS_18V@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r13d
	movb	(%rax), %cl
	shll	%cl, %r13d
	testq	%rdx, %rdx
	je	LBB0_2
## %bb.1:
	movq	(%rdx), %rax
	testq	%rax, %rax
	je	LBB0_2
## %bb.7:
	movq	%r14, %rdi
	movq	%r15, %rsi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmpq	*%rax                           ## TAILCALL
LBB0_2:
	movq	_UHS_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_mci_readl
	movl	%eax, %ebx
	movq	(%r15), %rax
	movq	_MMC_SIGNAL_VOLTAGE_330@GOTPCREL(%rip), %rcx
	movl	%r13d, %edx
	notl	%edx
	andl	%ebx, %edx
	orl	%r13d, %ebx
	cmpq	(%rcx), %rax
	cmovel	%edx, %ebx
	movl	4(%r14), %edi
	callq	_IS_ERR
	testl	%eax, %eax
	je	LBB0_3
LBB0_5:
	movq	_UHS_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	%ebx, %edx
	callq	_mci_writel
	xorl	%r15d, %r15d
	jmp	LBB0_6
LBB0_3:
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_mmc_regulator_set_vqmmc
	testl	%eax, %eax
	je	LBB0_5
## %bb.4:
	movl	%eax, %r15d
	testl	%r13d, %ebx
	leaq	L_.str.2(%rip), %rax
	leaq	L_.str.1(%rip), %rcx
	cmoveq	%rax, %rcx
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%r15d, %edx
	callq	_dev_dbg
LBB0_6:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SDMMC_UHS_18V,4,2              ## @SDMMC_UHS_18V
	.comm	_UHS_REG,4,2                    ## @UHS_REG
	.comm	_MMC_SIGNAL_VOLTAGE_330,8,3     ## @MMC_SIGNAL_VOLTAGE_330
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Regulator set error %d - %s V\n"

L_.str.1:                               ## @.str.1
	.asciz	"1.8"

L_.str.2:                               ## @.str.2
	.asciz	"3.3"

	.no_dead_strip	_dw_mci_switch_voltage
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dw_mci_switch_voltage
_dw_mci_switch_voltage:                 ; @dw_mci_switch_voltage
	.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	x20, x1
	mov	x19, x0
	bl	_mmc_priv
	ldr	x21, [x0, #8]
	ldr	x10, [x21]
Lloh0:
	adrp	x8, _SDMMC_UHS_18V@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SDMMC_UHS_18V@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x0]
	cbz	x10, LBB0_3
; %bb.1:
	ldr	x2, [x10]
	cbz	x2, LBB0_3
; %bb.2:
	mov	x0, x19
	mov	x1, x20
	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
	br	x2
LBB0_3:
	lsl	w23, w8, w9
Lloh3:
	adrp	x24, _UHS_REG@GOTPAGE
Lloh4:
	ldr	x24, [x24, _UHS_REG@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	x0, x21
	bl	_mci_readl
	ldr	x8, [x20]
Lloh5:
	adrp	x9, _MMC_SIGNAL_VOLTAGE_330@GOTPAGE
Lloh6:
	ldr	x9, [x9, _MMC_SIGNAL_VOLTAGE_330@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	bic	w10, w0, w23
	orr	w11, w0, w23
	cmp	x8, x9
	csel	w22, w10, w11, eq
	ldr	w0, [x19, #4]
	bl	_IS_ERR
	cbz	w0, LBB0_5
LBB0_4:
	ldr	w1, [x24]
	mov	x0, x21
	mov	x2, x22
	bl	_mci_writel
	mov	w20, #0
	b	LBB0_7
LBB0_5:
	mov	x0, x19
	mov	x1, x20
	bl	_mmc_regulator_set_vqmmc
	cbz	w0, LBB0_4
; %bb.6:
	mov	x20, x0
Lloh8:
	adrp	x8, l_.str.1@PAGE
Lloh9:
	add	x8, x8, l_.str.1@PAGEOFF
Lloh10:
	adrp	x9, l_.str.2@PAGE
Lloh11:
	add	x9, x9, l_.str.2@PAGEOFF
	tst	w22, w23
	csel	x3, x9, x8, eq
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x20
	bl	_dev_dbg
LBB0_7:
	mov	x0, x20
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_SDMMC_UHS_18V,4,2              ; @SDMMC_UHS_18V
	.comm	_UHS_REG,4,2                    ; @UHS_REG
	.comm	_MMC_SIGNAL_VOLTAGE_330,8,3     ; @MMC_SIGNAL_VOLTAGE_330
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Regulator set error %d - %s V\n"

l_.str.1:                               ; @.str.1
	.asciz	"1.8"

l_.str.2:                               ; @.str.2
	.asciz	"3.3"

	.no_dead_strip	_dw_mci_switch_voltage
.subsections_via_symbols
