	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function i965_enable_backlight
_i965_enable_backlight:                 ## @i965_enable_backlight
	.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, %r14
	movl	4(%rsi), %edi
	callq	_to_intel_connector
	movq	%rax, %r12
	movl	24(%rax), %edi
	callq	_to_i915
	movl	(%r14), %edi
	callq	_to_intel_crtc
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_BLC_PWM_CTL2@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	callq	_I915_READ
	movq	_BLM_PWM_ENABLE@GOTPCREL(%rip), %r13
	testl	%eax, (%r13)
	je	LBB0_2
## %bb.1:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rdi
	callq	_DRM_DEBUG_KMS
	movl	(%r13), %eax
	notl	%eax
	andl	%eax, %ebx
	movl	(%r15), %edi
	movl	%ebx, %esi
	callq	_I915_WRITE
LBB0_2:
	movl	(%r12), %esi
	cmpq	$0, 16(%r12)
	je	LBB0_4
## %bb.3:
	movslq	%esi, %rsi
	imulq	$-2139062143, %rsi, %rax        ## imm = 0x80808081
	shrq	$32, %rax
	addl	%eax, %esi
	movl	%esi, %eax
	shrl	$31, %eax
	sarl	$7, %esi
	addl	%eax, %esi
LBB0_4:
	movq	%r15, %r13
	shll	$16, %esi
	movq	_BLC_PWM_CTL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_I915_WRITE
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	callq	_BLM_PIPE
	xorl	%ecx, %ecx
	cmpq	$0, 16(%r12)
	movl	$0, %ebx
	je	LBB0_6
## %bb.5:
	movq	_BLM_COMBINATION_MODE@GOTPCREL(%rip), %rdx
	movl	(%rdx), %ebx
LBB0_6:
	orl	%eax, %ebx
	cmpq	$0, 8(%r12)
	movq	_BLM_PWM_ENABLE@GOTPCREL(%rip), %r15
	je	LBB0_8
## %bb.7:
	movq	_BLM_POLARITY_I965@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
LBB0_8:
	orl	%ecx, %ebx
	movl	(%r13), %edi
	movl	%ebx, %esi
	callq	_I915_WRITE
	movl	(%r13), %edi
	callq	_POSTING_READ
	movl	(%r13), %edi
	orl	(%r15), %ebx
	movl	%ebx, %esi
	callq	_I915_WRITE
	movl	4(%r12), %esi
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_intel_panel_actually_set_backlight ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_BLC_PWM_CTL2,4,2               ## @BLC_PWM_CTL2
	.comm	_BLM_PWM_ENABLE,4,2             ## @BLM_PWM_ENABLE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"backlight already enabled\n"

	.comm	_BLC_PWM_CTL,4,2                ## @BLC_PWM_CTL
	.comm	_BLM_COMBINATION_MODE,4,2       ## @BLM_COMBINATION_MODE
	.comm	_BLM_POLARITY_I965,4,2          ## @BLM_POLARITY_I965
	.no_dead_strip	_i965_enable_backlight
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function i965_enable_backlight
_i965_enable_backlight:                 ; @i965_enable_backlight
	.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	x19, x1
	ldr	w0, [x1, #4]
	bl	_to_intel_connector
	mov	x20, x0
	ldr	w0, [x0, #24]
	bl	_to_i915
	ldr	w0, [x19]
	bl	_to_intel_crtc
	ldr	w21, [x0]
Lloh0:
	adrp	x23, _BLC_PWM_CTL2@GOTPAGE
Lloh1:
	ldr	x23, [x23, _BLC_PWM_CTL2@GOTPAGEOFF]
	ldr	w0, [x23]
	bl	_I915_READ
Lloh2:
	adrp	x24, _BLM_PWM_ENABLE@GOTPAGE
Lloh3:
	ldr	x24, [x24, _BLM_PWM_ENABLE@GOTPAGEOFF]
	ldr	w8, [x24]
	tst	w8, w0
	b.eq	LBB0_2
; %bb.1:
	mov	x22, x0
Lloh4:
	adrp	x0, l_.str@PAGE
Lloh5:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG_KMS
	ldr	w8, [x24]
	bic	w1, w22, w8
	ldr	w0, [x23]
	bl	_I915_WRITE
LBB0_2:
	ldrsw	x8, [x20]
	ldr	x9, [x20, #16]
	mov	x10, #-32639
	movk	x10, #32896, lsl #16
	mul	x10, x8, x10
	lsr	x10, x10, #32
	add	w10, w10, w8
	asr	w11, w10, #7
	add	w10, w11, w10, lsr #31
	cmp	x9, #0
	csel	w8, w8, w10, eq
	lsl	w1, w8, #16
Lloh6:
	adrp	x8, _BLC_PWM_CTL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _BLC_PWM_CTL@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_I915_WRITE
	mov	x0, x21
	bl	_BLM_PIPE
Lloh9:
	adrp	x8, _BLM_COMBINATION_MODE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BLM_COMBINATION_MODE@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldp	x10, x9, [x20, #8]
	cmp	x9, #0
	csel	w8, wzr, w8, eq
Lloh12:
	adrp	x9, _BLM_POLARITY_I965@GOTPAGE
Lloh13:
	ldr	x9, [x9, _BLM_POLARITY_I965@GOTPAGEOFF]
	orr	w8, w8, w0
Lloh14:
	ldr	w9, [x9]
	cmp	x10, #0
	csel	w9, wzr, w9, eq
	orr	w21, w8, w9
	ldr	w0, [x23]
	mov	x1, x21
	bl	_I915_WRITE
	ldr	w0, [x23]
	bl	_POSTING_READ
	ldr	w0, [x23]
	ldr	w8, [x24]
	orr	w1, w8, w21
	bl	_I915_WRITE
	ldr	w1, [x20, #4]
	mov	x0, x19
	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
	b	_intel_panel_actually_set_backlight
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_BLC_PWM_CTL2,4,2               ; @BLC_PWM_CTL2
	.comm	_BLM_PWM_ENABLE,4,2             ; @BLM_PWM_ENABLE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"backlight already enabled\n"

	.comm	_BLC_PWM_CTL,4,2                ; @BLC_PWM_CTL
	.comm	_BLM_COMBINATION_MODE,4,2       ; @BLM_COMBINATION_MODE
	.comm	_BLM_POLARITY_I965,4,2          ; @BLM_POLARITY_I965
	.no_dead_strip	_i965_enable_backlight
.subsections_via_symbols
