	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function magicmouse_input_mapping
_magicmouse_input_mapping:              ## @magicmouse_input_mapping
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdx, %r14
	movq	%rsi, %rbx
	callq	_hid_get_drvdata
	cmpq	$0, (%rax)
	movq	(%rbx), %rcx
	jne	LBB0_2
## %bb.1:
	movq	%rcx, (%rax)
LBB0_2:
	movq	(%rcx), %rax
	movq	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_4
## %bb.3:
	movq	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD2@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_5
LBB0_4:
	movq	_HID_MAIN_ITEM_RELATIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	$-1, %eax
	testl	%ecx, (%r14)
	jne	LBB0_6
LBB0_5:
	xorl	%eax, %eax
LBB0_6:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD,8,3 ## @USB_DEVICE_ID_APPLE_MAGICTRACKPAD
	.comm	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD2,8,3 ## @USB_DEVICE_ID_APPLE_MAGICTRACKPAD2
	.comm	_HID_MAIN_ITEM_RELATIVE,4,2     ## @HID_MAIN_ITEM_RELATIVE
	.no_dead_strip	_magicmouse_input_mapping
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function magicmouse_input_mapping
_magicmouse_input_mapping:              ; @magicmouse_input_mapping
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x2
	mov	x20, x1
	bl	_hid_get_drvdata
	ldr	x9, [x0]
	ldr	x8, [x20]
	cbnz	x9, LBB0_2
; %bb.1:
	str	x8, [x0]
LBB0_2:
	ldr	x8, [x8]
Lloh0:
	adrp	x9, _USB_DEVICE_ID_APPLE_MAGICTRACKPAD@GOTPAGE
Lloh1:
	ldr	x9, [x9, _USB_DEVICE_ID_APPLE_MAGICTRACKPAD@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
Lloh3:
	adrp	x10, _USB_DEVICE_ID_APPLE_MAGICTRACKPAD2@GOTPAGE
Lloh4:
	ldr	x10, [x10, _USB_DEVICE_ID_APPLE_MAGICTRACKPAD2@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.ne	LBB0_5
; %bb.3:
	ldr	w8, [x19]
Lloh6:
	adrp	x9, _HID_MAIN_ITEM_RELATIVE@GOTPAGE
Lloh7:
	ldr	x9, [x9, _HID_MAIN_ITEM_RELATIVE@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_5
; %bb.4:
	mov	w0, #-1
	b	LBB0_6
LBB0_5:
	mov	w0, #0
LBB0_6:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD,8,3 ; @USB_DEVICE_ID_APPLE_MAGICTRACKPAD
	.comm	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD2,8,3 ; @USB_DEVICE_ID_APPLE_MAGICTRACKPAD2
	.comm	_HID_MAIN_ITEM_RELATIVE,4,2     ; @HID_MAIN_ITEM_RELATIVE
	.no_dead_strip	_magicmouse_input_mapping
.subsections_via_symbols
