	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ideapad_sync_touchpad_state
_ideapad_sync_touchpad_state:           ## @ideapad_sync_touchpad_state
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	movq	(%rdi), %rax
	movl	(%rax), %edi
	movq	_VPCCMD_R_TOUCHPAD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-24(%rbp), %rdx
	callq	_read_ec_data
	testl	%eax, %eax
	jne	LBB0_5
## %bb.1:
	cmpq	$0, -24(%rbp)
	jne	LBB0_2
## %bb.3:
	movq	_I8042_CMD_AUX_DISABLE@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_2:
	movq	_I8042_CMD_AUX_ENABLE@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %esi
	leaq	-9(%rbp), %rdi
	callq	_i8042_command
	cmpq	$1, -24(%rbp)
	movl	$67, %esi
	sbbl	$0, %esi
	movq	%rbx, %rdi
	callq	_ideapad_input_report
LBB0_5:
	addq	$24, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_VPCCMD_R_TOUCHPAD,4,2          ## @VPCCMD_R_TOUCHPAD
	.comm	_I8042_CMD_AUX_ENABLE,4,2       ## @I8042_CMD_AUX_ENABLE
	.comm	_I8042_CMD_AUX_DISABLE,4,2      ## @I8042_CMD_AUX_DISABLE
	.no_dead_strip	_ideapad_sync_touchpad_state
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ideapad_sync_touchpad_state
_ideapad_sync_touchpad_state:           ; @ideapad_sync_touchpad_state
	.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	x8, [x0]
	ldr	w0, [x8]
Lloh0:
	adrp	x8, _VPCCMD_R_TOUCHPAD@GOTPAGE
Lloh1:
	ldr	x8, [x8, _VPCCMD_R_TOUCHPAD@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x2, sp, #8
	bl	_read_ec_data
	cbnz	w0, LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _I8042_CMD_AUX_ENABLE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _I8042_CMD_AUX_ENABLE@GOTPAGEOFF]
	ldr	x9, [sp, #8]
Lloh5:
	adrp	x10, _I8042_CMD_AUX_DISABLE@GOTPAGE
Lloh6:
	ldr	x10, [x10, _I8042_CMD_AUX_DISABLE@GOTPAGEOFF]
	cmp	x9, #0
	csel	x8, x10, x8, eq
	ldr	w1, [x8]
	add	x0, sp, #7
	bl	_i8042_command
	ldr	x8, [sp, #8]
	cmp	x8, #0
	mov	w8, #66
	cinc	w1, w8, ne
	mov	x0, x19
	bl	_ideapad_input_report
LBB0_2:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_VPCCMD_R_TOUCHPAD,4,2          ; @VPCCMD_R_TOUCHPAD
	.comm	_I8042_CMD_AUX_ENABLE,4,2       ; @I8042_CMD_AUX_ENABLE
	.comm	_I8042_CMD_AUX_DISABLE,4,2      ; @I8042_CMD_AUX_DISABLE
	.no_dead_strip	_ideapad_sync_touchpad_state
.subsections_via_symbols
