	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stmpe1601_autosleep
_stmpe1601_autosleep:                   ## @stmpe1601_autosleep
	.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
	movl	%esi, %edi
	callq	_stmpe_round_timeout
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movq	(%r14), %rax
	movq	_STMPE_IDX_SYS_CTRL2@GOTPCREL(%rip), %r15
	movq	(%r15), %rcx
	movl	(%rax,%rcx,4), %esi
	movq	_STMPE1601_AUTOSLEEP_TIMEOUT_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	%ebx, %ecx
	callq	___stmpe_set_bits
	testl	%eax, %eax
	js	LBB0_3
## %bb.5:
	movq	(%r14), %rax
	movq	(%r15), %rcx
	movl	(%rax,%rcx,4), %esi
	movq	_STPME1601_AUTOSLEEP_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	movl	%ecx, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	___stmpe_set_bits               ## TAILCALL
LBB0_1:
	movl	8(%r14), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	jmp	LBB0_4
LBB0_3:
	movl	%eax, %ebx
LBB0_4:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid timeout\n"

	.comm	_STMPE_IDX_SYS_CTRL2,8,3        ## @STMPE_IDX_SYS_CTRL2
	.comm	_STMPE1601_AUTOSLEEP_TIMEOUT_MASK,4,2 ## @STMPE1601_AUTOSLEEP_TIMEOUT_MASK
	.comm	_STPME1601_AUTOSLEEP_ENABLE,4,2 ## @STPME1601_AUTOSLEEP_ENABLE
	.no_dead_strip	_stmpe1601_autosleep
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stmpe1601_autosleep
_stmpe1601_autosleep:                   ; @stmpe1601_autosleep
	.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
	mov	x20, x0
	mov	x0, x1
	bl	_stmpe_round_timeout
	mov	x19, x0
	tbnz	w0, #31, LBB0_3
; %bb.1:
	ldr	x8, [x20]
Lloh0:
	adrp	x21, _STMPE_IDX_SYS_CTRL2@GOTPAGE
Lloh1:
	ldr	x21, [x21, _STMPE_IDX_SYS_CTRL2@GOTPAGEOFF]
	ldr	x9, [x21]
	ldr	w1, [x8, x9, lsl #2]
Lloh2:
	adrp	x8, _STMPE1601_AUTOSLEEP_TIMEOUT_MASK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _STMPE1601_AUTOSLEEP_TIMEOUT_MASK@GOTPAGEOFF]
Lloh4:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x3, x19
	bl	___stmpe_set_bits
	tbnz	w0, #31, LBB0_4
; %bb.2:
	ldr	x8, [x20]
	ldr	x9, [x21]
	ldr	w1, [x8, x9, lsl #2]
Lloh5:
	adrp	x8, _STPME1601_AUTOSLEEP_ENABLE@GOTPAGE
Lloh6:
	ldr	x8, [x8, _STPME1601_AUTOSLEEP_ENABLE@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x3, x2
	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	___stmpe_set_bits
LBB0_3:
	ldr	w0, [x20, #8]
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
	b	LBB0_5
LBB0_4:
	mov	x19, x0
LBB0_5:
	mov	x0, x19
	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	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid timeout\n"

	.comm	_STMPE_IDX_SYS_CTRL2,8,3        ; @STMPE_IDX_SYS_CTRL2
	.comm	_STMPE1601_AUTOSLEEP_TIMEOUT_MASK,4,2 ; @STMPE1601_AUTOSLEEP_TIMEOUT_MASK
	.comm	_STPME1601_AUTOSLEEP_ENABLE,4,2 ; @STPME1601_AUTOSLEEP_ENABLE
	.no_dead_strip	_stmpe1601_autosleep
.subsections_via_symbols
