	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function chv_phy_control_init
_chv_phy_control_init:                  ## @chv_phy_control_init
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	movq	_VLV_DISP_PW_DPIO_CMN_BC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_lookup_power_well
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	_CHV_DISP_PW_DPIO_CMN_D@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_lookup_power_well
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	_PHY_LDO_DELAY_600NS@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	movq	_DPIO_PHY0@GOTPCREL(%rip), %r15
	movq	(%r15), %rsi
	callq	_PHY_LDO_SEQ_DELAY
	movl	%eax, %r12d
	movl	(%rbx), %edi
	movq	_DPIO_PHY1@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	callq	_PHY_LDO_SEQ_DELAY
	movl	%eax, %ebx
	orl	%r12d, %ebx
	movq	_PHY_CH_DEEP_PSR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rax, %r14
	movq	(%r15), %rsi
	movq	_DPIO_CH0@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_PHY_CH_POWER_MODE
	movl	%eax, %r12d
	movl	(%r14), %edi
	movq	(%r15), %rsi
	movq	_DPIO_CH1@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_PHY_CH_POWER_MODE
	movl	%eax, %r14d
	orl	%r12d, %r14d
	orl	%ebx, %r14d
	movq	_PHY_CH_DEEP_PSR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_DPIO_PHY1@GOTPCREL(%rip), %r12
	movq	(%r12), %rsi
	movq	_DPIO_CH0@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_PHY_CH_POWER_MODE
	orl	%r14d, %eax
	movl	%eax, (%r13)
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movq	(%rsi), %rax
	movq	(%rax), %rax
	movq	%r13, %rdi
	callq	*(%rax)
	movl	$1, %r14d
	movl	$1, %ecx
	testq	%rax, %rax
	je	LBB0_6
## %bb.1:
	movq	%r15, %r14
	movq	_PIPE_A@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_DPLL
	movl	%eax, %edi
	callq	_I915_READ
	movl	%eax, %r12d
	movq	_DPLL_PORTB_READY_MASK@GOTPCREL(%rip), %rax
	movl	%r12d, %ebx
	andl	(%rax), %ebx
	xorl	%r15d, %r15d
	movl	$0, %edi
	cmpl	$15, %ebx
	je	LBB0_3
## %bb.2:
	movq	(%r14), %rdi
	movq	_DPIO_CH0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_PHY_CH_POWER_DOWN_OVRD_EN
	orl	%eax, (%r13)
	movl	%ebx, %edi
LBB0_3:
	movq	(%r14), %rsi
	movq	_DPIO_CH0@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_PHY_CH_POWER_DOWN_OVRD
	orl	%eax, (%r13)
	movq	_DPLL_PORTC_READY_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	andl	%r12d, %ebx
	sarl	$4, %ebx
	cmpl	$15, %ebx
	movq	_DPIO_CH1@GOTPCREL(%rip), %r12
	je	LBB0_5
## %bb.4:
	movq	(%r14), %rdi
	movl	(%r12), %esi
	callq	_PHY_CH_POWER_DOWN_OVRD_EN
	orl	%eax, (%r13)
	movl	%ebx, %r15d
LBB0_5:
	movq	(%r14), %rsi
	movl	(%r12), %edx
	movl	%r15d, %edi
	callq	_PHY_CH_POWER_DOWN_OVRD
	orl	%eax, (%r13)
	movq	(%r14), %rdi
	callq	_PHY_COM_LANE_RESET_DEASSERT
	orl	%eax, (%r13)
	xorl	%ecx, %ecx
	movq	_DPIO_PHY1@GOTPCREL(%rip), %r12
	movq	%r14, %r15
	movl	$1, %r14d
LBB0_6:
	movq	8(%r13), %rax
	movq	(%r15), %rdx
	movl	%ecx, (%rax,%rdx,4)
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movq	(%rsi), %rax
	movq	(%rax), %rax
	movq	%r13, %rdi
	callq	*(%rax)
	testq	%rax, %rax
	je	LBB0_10
## %bb.7:
	movq	_DPIO_PHY_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_I915_READ
	movl	%eax, %ebx
	movq	_DPLL_PORTD_READY_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	xorl	%r14d, %r14d
	movl	$0, %edi
	cmpl	$15, %ebx
	je	LBB0_9
## %bb.8:
	movq	(%r12), %rdi
	movq	_DPIO_CH0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_PHY_CH_POWER_DOWN_OVRD_EN
	orl	%eax, (%r13)
	movl	%ebx, %edi
LBB0_9:
	movq	(%r12), %rsi
	movq	_DPIO_CH0@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_PHY_CH_POWER_DOWN_OVRD
	orl	%eax, (%r13)
	movq	(%r12), %rdi
	callq	_PHY_COM_LANE_RESET_DEASSERT
	orl	%eax, (%r13)
LBB0_10:
	movq	8(%r13), %rax
	movq	(%r12), %rcx
	movl	%r14d, (%rax,%rcx,4)
	movq	_DISPLAY_PHY_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r13), %esi
	callq	_I915_WRITE
	movl	(%r13), %esi
	leaq	L_.str(%rip), %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DRM_DEBUG_KMS                  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_VLV_DISP_PW_DPIO_CMN_BC,4,2    ## @VLV_DISP_PW_DPIO_CMN_BC
	.comm	_CHV_DISP_PW_DPIO_CMN_D,4,2     ## @CHV_DISP_PW_DPIO_CMN_D
	.comm	_PHY_LDO_DELAY_600NS,4,2        ## @PHY_LDO_DELAY_600NS
	.comm	_DPIO_PHY0,8,3                  ## @DPIO_PHY0
	.comm	_DPIO_PHY1,8,3                  ## @DPIO_PHY1
	.comm	_PHY_CH_DEEP_PSR,4,2            ## @PHY_CH_DEEP_PSR
	.comm	_DPIO_CH0,4,2                   ## @DPIO_CH0
	.comm	_DPIO_CH1,4,2                   ## @DPIO_CH1
	.comm	_PIPE_A,4,2                     ## @PIPE_A
	.comm	_DPLL_PORTB_READY_MASK,4,2      ## @DPLL_PORTB_READY_MASK
	.comm	_DPLL_PORTC_READY_MASK,4,2      ## @DPLL_PORTC_READY_MASK
	.comm	_DPIO_PHY_STATUS,4,2            ## @DPIO_PHY_STATUS
	.comm	_DPLL_PORTD_READY_MASK,4,2      ## @DPLL_PORTD_READY_MASK
	.comm	_DISPLAY_PHY_CONTROL,4,2        ## @DISPLAY_PHY_CONTROL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Initial PHY_CONTROL=0x%08x\n"

	.no_dead_strip	_chv_phy_control_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function chv_phy_control_init
_chv_phy_control_init:                  ; @chv_phy_control_init
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
Lloh0:
	adrp	x8, _VLV_DISP_PW_DPIO_CMN_BC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _VLV_DISP_PW_DPIO_CMN_BC@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_lookup_power_well
	mov	x21, x0
Lloh3:
	adrp	x8, _CHV_DISP_PW_DPIO_CMN_D@GOTPAGE
Lloh4:
	ldr	x8, [x8, _CHV_DISP_PW_DPIO_CMN_D@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_lookup_power_well
	mov	x20, x0
Lloh6:
	adrp	x23, _PHY_LDO_DELAY_600NS@GOTPAGE
Lloh7:
	ldr	x23, [x23, _PHY_LDO_DELAY_600NS@GOTPAGEOFF]
	ldr	w0, [x23]
Lloh8:
	adrp	x25, _DPIO_PHY0@GOTPAGE
Lloh9:
	ldr	x25, [x25, _DPIO_PHY0@GOTPAGEOFF]
	ldr	x1, [x25]
	bl	_PHY_LDO_SEQ_DELAY
	mov	x22, x0
	ldr	w0, [x23]
Lloh10:
	adrp	x23, _DPIO_PHY1@GOTPAGE
Lloh11:
	ldr	x23, [x23, _DPIO_PHY1@GOTPAGEOFF]
	ldr	x1, [x23]
	bl	_PHY_LDO_SEQ_DELAY
Lloh12:
	adrp	x27, _PHY_CH_DEEP_PSR@GOTPAGE
Lloh13:
	ldr	x27, [x27, _PHY_CH_DEEP_PSR@GOTPAGEOFF]
	orr	w22, w0, w22
	ldr	w0, [x27]
	ldr	x1, [x25]
Lloh14:
	adrp	x24, _DPIO_CH0@GOTPAGE
Lloh15:
	ldr	x24, [x24, _DPIO_CH0@GOTPAGEOFF]
	ldr	w2, [x24]
	bl	_PHY_CH_POWER_MODE
	orr	w22, w22, w0
	ldr	w0, [x27]
	ldr	x1, [x25]
Lloh16:
	adrp	x26, _DPIO_CH1@GOTPAGE
Lloh17:
	ldr	x26, [x26, _DPIO_CH1@GOTPAGEOFF]
	ldr	w2, [x26]
	bl	_PHY_CH_POWER_MODE
	orr	w22, w22, w0
	ldr	w0, [x27]
	ldr	x1, [x23]
	ldr	w2, [x24]
	bl	_PHY_CH_POWER_MODE
	orr	w8, w22, w0
	str	w8, [x19]
	ldr	x8, [x21]
	ldr	x8, [x8]
	ldr	x8, [x8]
	mov	x0, x19
	mov	x1, x21
	blr	x8
	cbz	x0, LBB0_3
; %bb.1:
Lloh18:
	adrp	x8, _PIPE_A@GOTPAGE
Lloh19:
	ldr	x8, [x8, _PIPE_A@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	bl	_DPLL
	bl	_I915_READ
	mov	x21, x0
Lloh21:
	adrp	x8, _DPLL_PORTB_READY_MASK@GOTPAGE
Lloh22:
	ldr	x8, [x8, _DPLL_PORTB_READY_MASK@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	and	w22, w8, w0
	cmp	w22, #15
	b.ne	LBB0_4
; %bb.2:
	mov	w22, #0
	b	LBB0_5
LBB0_3:
	mov	w8, #1
	b	LBB0_9
LBB0_4:
	ldr	x0, [x25]
	ldr	w1, [x24]
	bl	_PHY_CH_POWER_DOWN_OVRD_EN
	ldr	w8, [x19]
	orr	w8, w8, w0
	str	w8, [x19]
LBB0_5:
	ldr	x1, [x25]
	ldr	w2, [x24]
	mov	x0, x22
	bl	_PHY_CH_POWER_DOWN_OVRD
	ldr	w8, [x19]
	orr	w8, w8, w0
	str	w8, [x19]
Lloh24:
	adrp	x8, _DPLL_PORTC_READY_MASK@GOTPAGE
Lloh25:
	ldr	x8, [x8, _DPLL_PORTC_READY_MASK@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	and	w8, w8, w21
	asr	w21, w8, #4
	cmp	w21, #15
	b.ne	LBB0_7
; %bb.6:
	mov	w21, #0
	b	LBB0_8
LBB0_7:
	ldr	x0, [x25]
	ldr	w1, [x26]
	bl	_PHY_CH_POWER_DOWN_OVRD_EN
	ldr	w8, [x19]
	orr	w8, w8, w0
	str	w8, [x19]
LBB0_8:
	ldr	x1, [x25]
	ldr	w2, [x26]
	mov	x0, x21
	bl	_PHY_CH_POWER_DOWN_OVRD
	ldr	w8, [x19]
	orr	w8, w8, w0
	str	w8, [x19]
	ldr	x0, [x25]
	bl	_PHY_COM_LANE_RESET_DEASSERT
	mov	w8, #0
	ldr	w9, [x19]
	orr	w9, w9, w0
	str	w9, [x19]
LBB0_9:
	ldr	x9, [x19, #8]
	ldr	x10, [x25]
	str	w8, [x9, x10, lsl #2]
	ldr	x8, [x20]
	ldr	x8, [x8]
	ldr	x8, [x8]
	mov	x0, x19
	mov	x1, x20
	blr	x8
	cbz	x0, LBB0_12
; %bb.10:
Lloh27:
	adrp	x8, _DPIO_PHY_STATUS@GOTPAGE
Lloh28:
	ldr	x8, [x8, _DPIO_PHY_STATUS@GOTPAGEOFF]
Lloh29:
	ldr	w0, [x8]
	bl	_I915_READ
Lloh30:
	adrp	x8, _DPLL_PORTD_READY_MASK@GOTPAGE
Lloh31:
	ldr	x8, [x8, _DPLL_PORTD_READY_MASK@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	and	w20, w8, w0
	cmp	w20, #15
	b.ne	LBB0_13
; %bb.11:
	mov	w20, #0
	b	LBB0_14
LBB0_12:
	mov	w8, #1
	b	LBB0_15
LBB0_13:
	ldr	x0, [x23]
	ldr	w1, [x24]
	bl	_PHY_CH_POWER_DOWN_OVRD_EN
	ldr	w8, [x19]
	orr	w8, w8, w0
	str	w8, [x19]
LBB0_14:
	ldr	x1, [x23]
	ldr	w2, [x24]
	mov	x0, x20
	bl	_PHY_CH_POWER_DOWN_OVRD
	ldr	w8, [x19]
	orr	w8, w8, w0
	str	w8, [x19]
	ldr	x0, [x23]
	bl	_PHY_COM_LANE_RESET_DEASSERT
	mov	w8, #0
	ldr	w9, [x19]
	orr	w9, w9, w0
	str	w9, [x19]
LBB0_15:
	ldr	x9, [x19, #8]
	ldr	x10, [x23]
	str	w8, [x9, x10, lsl #2]
Lloh33:
	adrp	x8, _DISPLAY_PHY_CONTROL@GOTPAGE
Lloh34:
	ldr	x8, [x8, _DISPLAY_PHY_CONTROL@GOTPAGEOFF]
Lloh35:
	ldr	w0, [x8]
	ldr	w1, [x19]
	bl	_I915_WRITE
	ldr	w1, [x19]
Lloh36:
	adrp	x0, l_.str@PAGE
Lloh37:
	add	x0, x0, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_DRM_DEBUG_KMS
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.comm	_VLV_DISP_PW_DPIO_CMN_BC,4,2    ; @VLV_DISP_PW_DPIO_CMN_BC
	.comm	_CHV_DISP_PW_DPIO_CMN_D,4,2     ; @CHV_DISP_PW_DPIO_CMN_D
	.comm	_PHY_LDO_DELAY_600NS,4,2        ; @PHY_LDO_DELAY_600NS
	.comm	_DPIO_PHY0,8,3                  ; @DPIO_PHY0
	.comm	_DPIO_PHY1,8,3                  ; @DPIO_PHY1
	.comm	_PHY_CH_DEEP_PSR,4,2            ; @PHY_CH_DEEP_PSR
	.comm	_DPIO_CH0,4,2                   ; @DPIO_CH0
	.comm	_DPIO_CH1,4,2                   ; @DPIO_CH1
	.comm	_PIPE_A,4,2                     ; @PIPE_A
	.comm	_DPLL_PORTB_READY_MASK,4,2      ; @DPLL_PORTB_READY_MASK
	.comm	_DPLL_PORTC_READY_MASK,4,2      ; @DPLL_PORTC_READY_MASK
	.comm	_DPIO_PHY_STATUS,4,2            ; @DPIO_PHY_STATUS
	.comm	_DPLL_PORTD_READY_MASK,4,2      ; @DPLL_PORTD_READY_MASK
	.comm	_DISPLAY_PHY_CONTROL,4,2        ; @DISPLAY_PHY_CONTROL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Initial PHY_CONTROL=0x%08x\n"

	.no_dead_strip	_chv_phy_control_init
.subsections_via_symbols
