	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function acpi_atlas_button_handler
_acpi_atlas_button_handler:             ## @acpi_atlas_button_handler
	.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	_ACPI_WRITE@GOTPCREL(%rip), %rdx
	cmpq	%rdi, (%rdx)
	jne	LBB0_2
## %bb.1:
	movl	%esi, %ebx
	andl	$15, %ebx
	xorl	%r14d, %r14d
	testb	$16, %sil
	sete	%r14b
	movq	_input_dev@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	movq	_EV_MSC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_MSC_SCAN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%ebx, %ecx
	callq	_input_event
	movl	(%r15), %edi
	movq	_atlas_keymap@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax,%rbx,4), %esi
	movl	%r14d, %edx
	callq	_input_report_key
	movl	(%r15), %edi
	callq	_input_sync
	movq	_AE_OK@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_2:
	movq	%rdi, %rax
	movslq	%esi, %rdx
	movq	(%rcx), %rcx
	leaq	L_.str(%rip), %rdi
	movq	%rax, %rsi
	callq	_pr_warn
	movq	_AE_BAD_PARAMETER@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ACPI_WRITE,8,3                 ## @ACPI_WRITE
	.comm	_input_dev,4,2                  ## @input_dev
	.comm	_EV_MSC,4,2                     ## @EV_MSC
	.comm	_MSC_SCAN,4,2                   ## @MSC_SCAN
	.comm	_atlas_keymap,8,3               ## @atlas_keymap
	.comm	_AE_OK,4,2                      ## @AE_OK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"shrugged on unexpected function: function=%x,address=%lx,value=%x\n"

	.comm	_AE_BAD_PARAMETER,4,2           ## @AE_BAD_PARAMETER
	.no_dead_strip	_acpi_atlas_button_handler
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function acpi_atlas_button_handler
_acpi_atlas_button_handler:             ; @acpi_atlas_button_handler
	.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
                                        ; kill: def $w1 killed $w1 def $x1
Lloh0:
	adrp	x9, _ACPI_WRITE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ACPI_WRITE@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x9, x0
	b.ne	LBB0_2
; %bb.1:
	and	w19, w1, #0xf
	mov	w8, #1
	bic	w20, w8, w1, lsr #4
Lloh3:
	adrp	x21, _input_dev@GOTPAGE
Lloh4:
	ldr	x21, [x21, _input_dev@GOTPAGEOFF]
	ldr	w0, [x21]
Lloh5:
	adrp	x8, _EV_MSC@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EV_MSC@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
Lloh8:
	adrp	x8, _MSC_SCAN@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MSC_SCAN@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	mov	x3, x19
	bl	_input_event
	ldr	w0, [x21]
Lloh11:
	adrp	x8, _atlas_keymap@GOTPAGE
Lloh12:
	ldr	x8, [x8, _atlas_keymap@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
	ldr	w1, [x8, w19, uxtw #2]
	mov	x2, x20
	bl	_input_report_key
	ldr	w0, [x21]
	bl	_input_sync
Lloh14:
	adrp	x8, _AE_OK@GOTPAGE
Lloh15:
	ldr	x8, [x8, _AE_OK@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:
	mov	x8, x0
	sxtw	x2, w1
	ldr	x3, [x3]
Lloh16:
	adrp	x0, l_.str@PAGE
Lloh17:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x8
	bl	_pr_warn
Lloh18:
	adrp	x8, _AE_BAD_PARAMETER@GOTPAGE
Lloh19:
	ldr	x8, [x8, _AE_BAD_PARAMETER@GOTPAGEOFF]
LBB0_3:
	ldr	w0, [x8]
	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
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_ACPI_WRITE,8,3                 ; @ACPI_WRITE
	.comm	_input_dev,4,2                  ; @input_dev
	.comm	_EV_MSC,4,2                     ; @EV_MSC
	.comm	_MSC_SCAN,4,2                   ; @MSC_SCAN
	.comm	_atlas_keymap,8,3               ; @atlas_keymap
	.comm	_AE_OK,4,2                      ; @AE_OK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"shrugged on unexpected function: function=%x,address=%lx,value=%x\n"

	.comm	_AE_BAD_PARAMETER,4,2           ; @AE_BAD_PARAMETER
	.no_dead_strip	_acpi_atlas_button_handler
.subsections_via_symbols
