	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pm1_enable_handler
_pm1_enable_handler:                    ## @pm1_enable_handler
	.cfi_startproc
## %bb.0:
	movl	$-1, %eax
	cmpl	$2, %r8d
	jne	LBB0_5
## %bb.1:
	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	%r9, %r15
	movl	%edx, %ebx
	movq	%rdi, %r14
	movq	_pm_lock@GOTPCREL(%rip), %rdi
	callq	_pthread_mutex_lock
	testl	%ebx, %ebx
	je	LBB0_3
## %bb.2:
	movq	_pm1_enable@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%r15)
	jmp	LBB0_4
LBB0_3:
	movq	_PM1_PWRBTN_EN@GOTPCREL(%rip), %rax
	movq	_PM1_GBL_EN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	andl	(%r15), %ecx
	movq	_pm1_enable@GOTPCREL(%rip), %rax
	movl	%ecx, (%rax)
	movq	%r14, %rdi
	callq	_sci_update
LBB0_4:
	movq	_pm_lock@GOTPCREL(%rip), %rdi
	callq	_pthread_mutex_unlock
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
LBB0_5:
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_pm_lock,4,2                    ## @pm_lock
	.comm	_pm1_enable,4,2                 ## @pm1_enable
	.comm	_PM1_PWRBTN_EN,4,2              ## @PM1_PWRBTN_EN
	.comm	_PM1_GBL_EN,4,2                 ## @PM1_GBL_EN
	.no_dead_strip	_pm1_enable_handler
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pm1_enable_handler
_pm1_enable_handler:                    ; @pm1_enable_handler
	.cfi_startproc
; %bb.0:
	cmp	w4, #2
	b.ne	LBB0_3
; %bb.1:
	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
	.cfi_remember_state
	mov	x20, x5
	mov	x21, x2
	mov	x19, x0
Lloh0:
	adrp	x0, _pm_lock@GOTPAGE
Lloh1:
	ldr	x0, [x0, _pm_lock@GOTPAGEOFF]
	bl	_pthread_mutex_lock
	cbz	w21, LBB0_4
; %bb.2:
Lloh2:
	adrp	x8, _pm1_enable@GOTPAGE
Lloh3:
	ldr	x8, [x8, _pm1_enable@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	str	w8, [x20]
	b	LBB0_5
LBB0_3:
	.cfi_def_cfa wsp, 0
	.cfi_same_value w30
	.cfi_same_value w29
	.cfi_same_value w19
	.cfi_same_value w20
	.cfi_same_value w21
	.cfi_same_value w22
	mov	w0, #-1
	ret
LBB0_4:
	.cfi_restore_state
	ldr	w8, [x20]
Lloh5:
	adrp	x9, _PM1_PWRBTN_EN@GOTPAGE
Lloh6:
	ldr	x9, [x9, _PM1_PWRBTN_EN@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
Lloh8:
	adrp	x10, _PM1_GBL_EN@GOTPAGE
Lloh9:
	ldr	x10, [x10, _PM1_GBL_EN@GOTPAGEOFF]
Lloh10:
	ldr	w10, [x10]
	orr	w9, w10, w9
	and	w8, w9, w8
Lloh11:
	adrp	x9, _pm1_enable@GOTPAGE
Lloh12:
	ldr	x9, [x9, _pm1_enable@GOTPAGEOFF]
Lloh13:
	str	w8, [x9]
	mov	x0, x19
	bl	_sci_update
LBB0_5:
Lloh14:
	adrp	x0, _pm_lock@GOTPAGE
Lloh15:
	ldr	x0, [x0, _pm_lock@GOTPAGEOFF]
	bl	_pthread_mutex_unlock
	mov	w0, #0
	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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotStr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_pm_lock,4,2                    ; @pm_lock
	.comm	_pm1_enable,4,2                 ; @pm1_enable
	.comm	_PM1_PWRBTN_EN,4,2              ; @PM1_PWRBTN_EN
	.comm	_PM1_GBL_EN,4,2                 ; @PM1_GBL_EN
	.no_dead_strip	_pm1_enable_handler
.subsections_via_symbols
