	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function il3945_set_pwr_vmain
_il3945_set_pwr_vmain:                  ## @il3945_set_pwr_vmain
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	movq	_APMG_PS_CTRL_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_APMG_PS_CTRL_VAL_PWR_SRC_VMAIN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_APMG_PS_CTRL_MSK_PWR_SRC@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	notl	%ecx
	callq	_il_set_bits_mask_prph
	movq	_CSR_GPIO_IN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_CSR_GPIO_IN_VAL_VMAIN_PWR_SRC@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_CSR_GPIO_IN_BIT_AUX_POWER@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	movl	$5000, %r8d                     ## imm = 0x1388
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	__il_poll_bit                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_APMG_PS_CTRL_REG,4,2           ## @APMG_PS_CTRL_REG
	.comm	_APMG_PS_CTRL_VAL_PWR_SRC_VMAIN,4,2 ## @APMG_PS_CTRL_VAL_PWR_SRC_VMAIN
	.comm	_APMG_PS_CTRL_MSK_PWR_SRC,4,2   ## @APMG_PS_CTRL_MSK_PWR_SRC
	.comm	_CSR_GPIO_IN,4,2                ## @CSR_GPIO_IN
	.comm	_CSR_GPIO_IN_VAL_VMAIN_PWR_SRC,4,2 ## @CSR_GPIO_IN_VAL_VMAIN_PWR_SRC
	.comm	_CSR_GPIO_IN_BIT_AUX_POWER,4,2  ## @CSR_GPIO_IN_BIT_AUX_POWER
	.no_dead_strip	_il3945_set_pwr_vmain
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function il3945_set_pwr_vmain
_il3945_set_pwr_vmain:                  ; @il3945_set_pwr_vmain
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
Lloh0:
	adrp	x8, _APMG_PS_CTRL_REG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _APMG_PS_CTRL_REG@GOTPAGEOFF]
Lloh2:
	adrp	x9, _APMG_PS_CTRL_VAL_PWR_SRC_VMAIN@GOTPAGE
Lloh3:
	ldr	x9, [x9, _APMG_PS_CTRL_VAL_PWR_SRC_VMAIN@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	ldr	w2, [x9]
Lloh6:
	adrp	x8, _APMG_PS_CTRL_MSK_PWR_SRC@GOTPAGE
Lloh7:
	ldr	x8, [x8, _APMG_PS_CTRL_MSK_PWR_SRC@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	mvn	w3, w8
	bl	_il_set_bits_mask_prph
Lloh9:
	adrp	x8, _CSR_GPIO_IN@GOTPAGE
Lloh10:
	ldr	x8, [x8, _CSR_GPIO_IN@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x8, _CSR_GPIO_IN_VAL_VMAIN_PWR_SRC@GOTPAGE
Lloh13:
	ldr	x8, [x8, _CSR_GPIO_IN_VAL_VMAIN_PWR_SRC@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
Lloh15:
	adrp	x8, _CSR_GPIO_IN_BIT_AUX_POWER@GOTPAGE
Lloh16:
	ldr	x8, [x8, _CSR_GPIO_IN_BIT_AUX_POWER@GOTPAGEOFF]
Lloh17:
	ldr	w3, [x8]
	mov	x0, x19
	mov	w4, #5000
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	__il_poll_bit
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_APMG_PS_CTRL_REG,4,2           ; @APMG_PS_CTRL_REG
	.comm	_APMG_PS_CTRL_VAL_PWR_SRC_VMAIN,4,2 ; @APMG_PS_CTRL_VAL_PWR_SRC_VMAIN
	.comm	_APMG_PS_CTRL_MSK_PWR_SRC,4,2   ; @APMG_PS_CTRL_MSK_PWR_SRC
	.comm	_CSR_GPIO_IN,4,2                ; @CSR_GPIO_IN
	.comm	_CSR_GPIO_IN_VAL_VMAIN_PWR_SRC,4,2 ; @CSR_GPIO_IN_VAL_VMAIN_PWR_SRC
	.comm	_CSR_GPIO_IN_BIT_AUX_POWER,4,2  ; @CSR_GPIO_IN_BIT_AUX_POWER
	.no_dead_strip	_il3945_set_pwr_vmain
.subsections_via_symbols
