	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function psb_intel_lvds_save
_psb_intel_lvds_save:                   ## @psb_intel_lvds_save
	.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
	movq	8(%r14), %r15
	callq	_gma_attached_encoder
	movq	(%rax), %rbx
	movq	_LVDSPP_ON@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_REG_READ
	movq	%rax, 40(%rbx)
	movq	_LVDSPP_OFF@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_REG_READ
	movq	%rax, 32(%rbx)
	movq	_LVDS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_REG_READ
	movq	%rax, 24(%rbx)
	movq	_PP_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_REG_READ
	movq	%rax, 16(%rbx)
	movq	_PP_CYCLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_REG_READ
	movq	%rax, 8(%rbx)
	movq	_BLC_PWM_CTL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_REG_READ
	movq	%rax, (%rbx)
	movq	_PFIT_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_REG_READ
	movq	%rax, 56(%rbx)
	movq	_PFIT_PGM_RATIOS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_REG_READ
	movq	%rax, 48(%rbx)
	movq	_BACKLIGHT_DUTY_CYCLE_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	4(%r15), %eax
	movl	%eax, (%r15)
	jne	LBB0_2
## %bb.1:
	movq	%r14, %rdi
	callq	_psb_intel_lvds_get_max_backlight
	movl	%eax, (%r15)
LBB0_2:
	movl	(%r14), %edi
	movq	40(%rbx), %rdx
	movq	32(%rbx), %rcx
	movq	24(%rbx), %r8
	movq	16(%rbx), %r9
	leaq	L_.str(%rip), %rsi
	pushq	(%rbx)
	pushq	8(%rbx)
	callq	_dev_dbg
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LVDSPP_ON,4,2                  ## @LVDSPP_ON
	.comm	_LVDSPP_OFF,4,2                 ## @LVDSPP_OFF
	.comm	_LVDS,4,2                       ## @LVDS
	.comm	_PP_CONTROL,4,2                 ## @PP_CONTROL
	.comm	_PP_CYCLE,4,2                   ## @PP_CYCLE
	.comm	_BLC_PWM_CTL,4,2                ## @BLC_PWM_CTL
	.comm	_PFIT_CONTROL,4,2               ## @PFIT_CONTROL
	.comm	_PFIT_PGM_RATIOS,4,2            ## @PFIT_PGM_RATIOS
	.comm	_BACKLIGHT_DUTY_CYCLE_MASK,4,2  ## @BACKLIGHT_DUTY_CYCLE_MASK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"(0x%x, 0x%x, 0x%x, 0x%x, 0x%x, 0x%x)\n"

	.no_dead_strip	_psb_intel_lvds_save
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function psb_intel_lvds_save
_psb_intel_lvds_save:                   ; @psb_intel_lvds_save
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	ldr	x19, [x0]
	ldr	x21, [x19, #8]
	bl	_gma_attached_encoder
	ldr	x20, [x0]
Lloh0:
	adrp	x8, _LVDSPP_ON@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LVDSPP_ON@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_REG_READ
	str	x0, [x20, #40]
Lloh3:
	adrp	x8, _LVDSPP_OFF@GOTPAGE
Lloh4:
	ldr	x8, [x8, _LVDSPP_OFF@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_REG_READ
	str	x0, [x20, #32]
Lloh6:
	adrp	x8, _LVDS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _LVDS@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_REG_READ
	str	x0, [x20, #24]
Lloh9:
	adrp	x8, _PP_CONTROL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _PP_CONTROL@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
	bl	_REG_READ
	str	x0, [x20, #16]
Lloh12:
	adrp	x8, _PP_CYCLE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _PP_CYCLE@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	bl	_REG_READ
	str	x0, [x20, #8]
Lloh15:
	adrp	x8, _BLC_PWM_CTL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _BLC_PWM_CTL@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	bl	_REG_READ
	str	x0, [x20]
Lloh18:
	adrp	x8, _PFIT_CONTROL@GOTPAGE
Lloh19:
	ldr	x8, [x8, _PFIT_CONTROL@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	bl	_REG_READ
	str	x0, [x20, #56]
Lloh21:
	adrp	x8, _PFIT_PGM_RATIOS@GOTPAGE
Lloh22:
	ldr	x8, [x8, _PFIT_PGM_RATIOS@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	bl	_REG_READ
	str	x0, [x20, #48]
	ldr	w8, [x21, #4]
Lloh24:
	adrp	x9, _BACKLIGHT_DUTY_CYCLE_MASK@GOTPAGE
Lloh25:
	ldr	x9, [x9, _BACKLIGHT_DUTY_CYCLE_MASK@GOTPAGEOFF]
Lloh26:
	ldr	w9, [x9]
	ands	w8, w9, w8
	str	w8, [x21]
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_psb_intel_lvds_get_max_backlight
	str	w0, [x21]
LBB0_2:
	ldr	w0, [x19]
	ldp	x3, x2, [x20, #32]
	ldp	x5, x4, [x20, #16]
	ldp	x7, x6, [x20]
Lloh27:
	adrp	x1, l_.str@PAGE
Lloh28:
	add	x1, x1, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_dev_dbg
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh27, Lloh28
	.cfi_endproc
                                        ; -- End function
	.comm	_LVDSPP_ON,4,2                  ; @LVDSPP_ON
	.comm	_LVDSPP_OFF,4,2                 ; @LVDSPP_OFF
	.comm	_LVDS,4,2                       ; @LVDS
	.comm	_PP_CONTROL,4,2                 ; @PP_CONTROL
	.comm	_PP_CYCLE,4,2                   ; @PP_CYCLE
	.comm	_BLC_PWM_CTL,4,2                ; @BLC_PWM_CTL
	.comm	_PFIT_CONTROL,4,2               ; @PFIT_CONTROL
	.comm	_PFIT_PGM_RATIOS,4,2            ; @PFIT_PGM_RATIOS
	.comm	_BACKLIGHT_DUTY_CYCLE_MASK,4,2  ; @BACKLIGHT_DUTY_CYCLE_MASK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"(0x%x, 0x%x, 0x%x, 0x%x, 0x%x, 0x%x)\n"

	.no_dead_strip	_psb_intel_lvds_save
.subsections_via_symbols
