	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tegra_mipi_power_down
_tegra_mipi_power_down:                 ## @tegra_mipi_power_down
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	8(%rdi), %edi
	callq	_clk_enable
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movq	_MIPI_CAL_BIAS_PAD_CFG2@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r14, %rdi
	callq	_tegra_mipi_readl
	movq	_MIPI_CAL_BIAS_PAD_PDVREG@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%rbx), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_tegra_mipi_writel
	movq	_MIPI_CAL_BIAS_PAD_CFG0@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%r14, %rdi
	callq	_tegra_mipi_readl
	movq	(%r14), %rcx
	movq	_MIPI_CAL_BIAS_PAD_E_VCLAMP_REF@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	notl	%edx
	xorl	%ebx, %ebx
	cmpq	$1, (%rcx)
	movl	$0, %esi
	sbbl	%esi, %esi
	orl	%edx, %esi
	andl	%eax, %esi
	movq	_MIPI_CAL_BIAS_PAD_PDVCLAMP@GOTPCREL(%rip), %rax
	orl	(%rax), %esi
	movl	(%r15), %edx
	movq	%r14, %rdi
	callq	_tegra_mipi_writel
	jmp	LBB0_3
LBB0_1:
	movl	%eax, %ebx
LBB0_3:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MIPI_CAL_BIAS_PAD_CFG2,4,2     ## @MIPI_CAL_BIAS_PAD_CFG2
	.comm	_MIPI_CAL_BIAS_PAD_PDVREG,4,2   ## @MIPI_CAL_BIAS_PAD_PDVREG
	.comm	_MIPI_CAL_BIAS_PAD_CFG0,4,2     ## @MIPI_CAL_BIAS_PAD_CFG0
	.comm	_MIPI_CAL_BIAS_PAD_E_VCLAMP_REF,4,2 ## @MIPI_CAL_BIAS_PAD_E_VCLAMP_REF
	.comm	_MIPI_CAL_BIAS_PAD_PDVCLAMP,4,2 ## @MIPI_CAL_BIAS_PAD_PDVCLAMP
	.no_dead_strip	_tegra_mipi_power_down
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tegra_mipi_power_down
_tegra_mipi_power_down:                 ; @tegra_mipi_power_down
	.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
	ldr	w0, [x0, #8]
	bl	_clk_enable
	tbnz	w0, #31, LBB0_2
; %bb.1:
Lloh0:
	adrp	x20, _MIPI_CAL_BIAS_PAD_CFG2@GOTPAGE
Lloh1:
	ldr	x20, [x20, _MIPI_CAL_BIAS_PAD_CFG2@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	bl	_tegra_mipi_readl
Lloh2:
	adrp	x8, _MIPI_CAL_BIAS_PAD_PDVREG@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MIPI_CAL_BIAS_PAD_PDVREG@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	orr	w1, w8, w0
	ldr	w2, [x20]
	mov	x0, x19
	bl	_tegra_mipi_writel
Lloh5:
	adrp	x20, _MIPI_CAL_BIAS_PAD_CFG0@GOTPAGE
Lloh6:
	ldr	x20, [x20, _MIPI_CAL_BIAS_PAD_CFG0@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	bl	_tegra_mipi_readl
	ldr	x8, [x19]
	ldr	x8, [x8]
Lloh7:
	adrp	x9, _MIPI_CAL_BIAS_PAD_E_VCLAMP_REF@GOTPAGE
Lloh8:
	ldr	x9, [x9, _MIPI_CAL_BIAS_PAD_E_VCLAMP_REF@GOTPAGEOFF]
Lloh9:
	ldr	w9, [x9]
	cmp	x8, #0
	mov	w8, #-1
	csinv	w8, w8, w9, eq
	and	w8, w8, w0
Lloh10:
	adrp	x9, _MIPI_CAL_BIAS_PAD_PDVCLAMP@GOTPAGE
Lloh11:
	ldr	x9, [x9, _MIPI_CAL_BIAS_PAD_PDVCLAMP@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	orr	w1, w8, w9
	ldr	w2, [x20]
	mov	x0, x19
	bl	_tegra_mipi_writel
	mov	w0, #0
LBB0_2:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_MIPI_CAL_BIAS_PAD_CFG2,4,2     ; @MIPI_CAL_BIAS_PAD_CFG2
	.comm	_MIPI_CAL_BIAS_PAD_PDVREG,4,2   ; @MIPI_CAL_BIAS_PAD_PDVREG
	.comm	_MIPI_CAL_BIAS_PAD_CFG0,4,2     ; @MIPI_CAL_BIAS_PAD_CFG0
	.comm	_MIPI_CAL_BIAS_PAD_E_VCLAMP_REF,4,2 ; @MIPI_CAL_BIAS_PAD_E_VCLAMP_REF
	.comm	_MIPI_CAL_BIAS_PAD_PDVCLAMP,4,2 ; @MIPI_CAL_BIAS_PAD_PDVCLAMP
	.no_dead_strip	_tegra_mipi_power_down
.subsections_via_symbols
