	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function asus_backlight_init
_asus_backlight_init:                   ## @asus_backlight_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movl	16(%rdi), %edi
	movq	_METHOD_BRIGHTNESS_GET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%r14d, %r14d
	xorl	%edx, %edx
	callq	_acpi_check_handle
	testq	%rax, %rax
	jne	LBB0_5
## %bb.1:
	movl	16(%rbx), %edi
	movq	_METHOD_BRIGHTNESS_SET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%r14d, %r14d
	xorl	%edx, %edx
	callq	_acpi_check_handle
	testq	%rax, %rax
	jne	LBB0_5
## %bb.2:
	leaq	-32(%rbp), %r15
	xorl	%r14d, %r14d
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movl	$15, -32(%rbp)
	movq	_BACKLIGHT_PLATFORM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -28(%rbp)
	movq	_ASUS_LAPTOP_FILE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	8(%rbx), %rsi
	movq	_asusbl_ops@GOTPCREL(%rip), %rcx
	movq	%rbx, %rdx
	movq	%r15, %r8
	callq	_backlight_device_register
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rdi
	callq	_pr_err
	movq	$0, (%rbx)
	movq	%r15, %rdi
	callq	_PTR_ERR
	movl	%eax, %r14d
	jmp	LBB0_5
LBB0_4:
	movq	%r15, (%rbx)
	movq	%r15, %rdi
	callq	_asus_read_brightness
	movl	%eax, 4(%r15)
	movq	_FB_BLANK_UNBLANK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%r15)
	movq	%r15, %rdi
	callq	_backlight_update_status
LBB0_5:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_METHOD_BRIGHTNESS_GET,4,2      ## @METHOD_BRIGHTNESS_GET
	.comm	_METHOD_BRIGHTNESS_SET,4,2      ## @METHOD_BRIGHTNESS_SET
	.comm	_BACKLIGHT_PLATFORM,4,2         ## @BACKLIGHT_PLATFORM
	.comm	_ASUS_LAPTOP_FILE,4,2           ## @ASUS_LAPTOP_FILE
	.comm	_asusbl_ops,4,2                 ## @asusbl_ops
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Could not register asus backlight device\n"

	.comm	_FB_BLANK_UNBLANK,4,2           ## @FB_BLANK_UNBLANK
	.no_dead_strip	_asus_backlight_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function asus_backlight_init
_asus_backlight_init:                   ; @asus_backlight_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
	ldr	w0, [x0, #16]
Lloh0:
	adrp	x8, _METHOD_BRIGHTNESS_GET@GOTPAGE
Lloh1:
	ldr	x8, [x8, _METHOD_BRIGHTNESS_GET@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x2, #0
	bl	_acpi_check_handle
	cbnz	x0, LBB0_2
; %bb.1:
	ldr	w0, [x19, #16]
Lloh3:
	adrp	x8, _METHOD_BRIGHTNESS_SET@GOTPAGE
Lloh4:
	ldr	x8, [x8, _METHOD_BRIGHTNESS_SET@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x2, #0
	bl	_acpi_check_handle
	cbz	x0, LBB0_4
LBB0_2:
	mov	w0, #0
LBB0_3:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_4:
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #8
	bl	_memset
	mov	w8, #15
Lloh6:
	adrp	x9, _BACKLIGHT_PLATFORM@GOTPAGE
Lloh7:
	ldr	x9, [x9, _BACKLIGHT_PLATFORM@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #8]
Lloh9:
	adrp	x8, _ASUS_LAPTOP_FILE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ASUS_LAPTOP_FILE@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
	ldr	x1, [x19, #8]
Lloh12:
	adrp	x3, _asusbl_ops@GOTPAGE
Lloh13:
	ldr	x3, [x3, _asusbl_ops@GOTPAGEOFF]
	add	x4, sp, #8
	mov	x2, x19
	bl	_backlight_device_register
	mov	x20, x0
	bl	_IS_ERR
	cbz	x0, LBB0_6
; %bb.5:
Lloh14:
	adrp	x0, l_.str@PAGE
Lloh15:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_err
	str	xzr, [x19]
	mov	x0, x20
	bl	_PTR_ERR
	b	LBB0_3
LBB0_6:
	str	x20, [x19]
	mov	x0, x20
	bl	_asus_read_brightness
Lloh16:
	adrp	x8, _FB_BLANK_UNBLANK@GOTPAGE
Lloh17:
	ldr	x8, [x8, _FB_BLANK_UNBLANK@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	stp	w8, w0, [x20]
	mov	x0, x20
	bl	_backlight_update_status
	b	LBB0_2
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_METHOD_BRIGHTNESS_GET,4,2      ; @METHOD_BRIGHTNESS_GET
	.comm	_METHOD_BRIGHTNESS_SET,4,2      ; @METHOD_BRIGHTNESS_SET
	.comm	_BACKLIGHT_PLATFORM,4,2         ; @BACKLIGHT_PLATFORM
	.comm	_ASUS_LAPTOP_FILE,4,2           ; @ASUS_LAPTOP_FILE
	.comm	_asusbl_ops,4,2                 ; @asusbl_ops
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Could not register asus backlight device\n"

	.comm	_FB_BLANK_UNBLANK,4,2           ; @FB_BLANK_UNBLANK
	.no_dead_strip	_asus_backlight_init
.subsections_via_symbols
