	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function alps_update_dual_info_ss4_v2
_alps_update_dual_info_ss4_v2:          ## @alps_update_dual_info_ss4_v2
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %r12
	movq	%rdi, %rbx
	movl	4(%rsi), %edi
	callq	_IS_SS4PLUS_DEV
	testq	%rax, %rax
	je	LBB0_8
## %bb.1:
	testb	$16, (%rbx)
	jne	LBB0_7
## %bb.2:
	movq	%r14, %rdi
	callq	_alps_exit_command_mode
	testq	%rax, %rax
	jne	LBB0_4
## %bb.3:
	movq	%r14, %rdi
	callq	_alps_enter_command_mode
	testq	%rax, %rax
	je	LBB0_5
LBB0_4:
	movq	%r14, %rdi
	callq	_alps_exit_command_mode
	movq	_PSMOUSE_CMD_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_ps2_command
	jmp	LBB0_8
LBB0_5:
	movq	%r14, %rdi
	movl	$215, %esi
	callq	_alps_command_mode_read_reg
	movl	%eax, %r15d
	movq	%r14, %rdi
	callq	_alps_exit_command_mode
	movq	_PSMOUSE_CMD_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_ps2_command
	cmpl	$29, %r15d
	je	LBB0_7
## %bb.6:
	cmpl	$12, %r15d
	jne	LBB0_8
LBB0_7:
	movq	_ALPS_DUALPOINT@GOTPCREL(%rip), %rax
	movq	_ALPS_DUALPOINT_WITH_PRESSURE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	orl	%ecx, (%r12)
LBB0_8:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PSMOUSE_CMD_ENABLE,4,2         ## @PSMOUSE_CMD_ENABLE
	.comm	_ALPS_DUALPOINT,4,2             ## @ALPS_DUALPOINT
	.comm	_ALPS_DUALPOINT_WITH_PRESSURE,4,2 ## @ALPS_DUALPOINT_WITH_PRESSURE
	.no_dead_strip	_alps_update_dual_info_ss4_v2
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function alps_update_dual_info_ss4_v2
_alps_update_dual_info_ss4_v2:          ; @alps_update_dual_info_ss4_v2
	.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, x2
	mov	x19, x1
	mov	x21, x0
	ldr	w0, [x1, #4]
	bl	_IS_SS4PLUS_DEV
	cbz	x0, LBB0_8
; %bb.1:
	ldrb	w8, [x21]
	tbnz	w8, #4, LBB0_7
; %bb.2:
	mov	x0, x20
	bl	_alps_exit_command_mode
	cbnz	x0, LBB0_4
; %bb.3:
	mov	x0, x20
	bl	_alps_enter_command_mode
	cbz	x0, LBB0_5
LBB0_4:
	mov	x0, x20
	bl	_alps_exit_command_mode
Lloh0:
	adrp	x8, _PSMOUSE_CMD_ENABLE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PSMOUSE_CMD_ENABLE@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x1, #0
	bl	_ps2_command
	b	LBB0_8
LBB0_5:
	mov	x0, x20
	mov	w1, #215
	bl	_alps_command_mode_read_reg
	mov	x21, x0
	mov	x0, x20
	bl	_alps_exit_command_mode
Lloh3:
	adrp	x8, _PSMOUSE_CMD_ENABLE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PSMOUSE_CMD_ENABLE@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x1, #0
	bl	_ps2_command
	cmp	w21, #29
	b.eq	LBB0_7
; %bb.6:
	cmp	w21, #12
	b.ne	LBB0_8
LBB0_7:
Lloh6:
	adrp	x8, _ALPS_DUALPOINT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ALPS_DUALPOINT@GOTPAGEOFF]
Lloh8:
	adrp	x9, _ALPS_DUALPOINT_WITH_PRESSURE@GOTPAGE
Lloh9:
	ldr	x9, [x9, _ALPS_DUALPOINT_WITH_PRESSURE@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
Lloh11:
	ldr	w9, [x9]
	orr	w8, w9, w8
	ldr	w9, [x19]
	orr	w8, w8, w9
	str	w8, [x19]
LBB0_8:
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_PSMOUSE_CMD_ENABLE,4,2         ; @PSMOUSE_CMD_ENABLE
	.comm	_ALPS_DUALPOINT,4,2             ; @ALPS_DUALPOINT
	.comm	_ALPS_DUALPOINT_WITH_PRESSURE,4,2 ; @ALPS_DUALPOINT_WITH_PRESSURE
	.no_dead_strip	_alps_update_dual_info_ss4_v2
.subsections_via_symbols
