	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hidpp_validate_device
_hidpp_validate_device:                 ## @hidpp_validate_device
	.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	%rdi, %r12
	callq	_hid_get_drvdata
	movq	%rax, %r14
	movq	_REPORT_ID_HIDPP_SHORT@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_hidpp_get_report_length
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movq	_HIDPP_REPORT_SHORT_LENGTH@GOTPCREL(%rip), %rcx
	movl	$1, %r15d
	cmpl	(%rcx), %eax
	jge	LBB0_3
	jmp	LBB0_10
LBB0_1:
	xorl	%r15d, %r15d
LBB0_3:
	movq	_REPORT_ID_HIDPP_LONG@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_hidpp_get_report_length
	testl	%eax, %eax
	je	LBB0_6
## %bb.4:
	movq	_HIDPP_REPORT_LONG_LENGTH@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jl	LBB0_10
## %bb.5:
	incl	%r15d
LBB0_6:
	movq	_REPORT_ID_HIDPP_VERY_LONG@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_hidpp_get_report_length
	testl	%eax, %eax
	je	LBB0_11
## %bb.7:
	movq	_HIDPP_REPORT_LONG_LENGTH@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jl	LBB0_10
## %bb.8:
	movq	_HIDPP_REPORT_VERY_LONG_MAX_LENGTH@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jg	LBB0_10
## %bb.9:
	incl	%r15d
	movl	%eax, (%r14)
	jmp	LBB0_11
LBB0_10:
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	movl	%ebx, %edx
	callq	_hid_warn
	xorl	%r15d, %r15d
LBB0_11:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_REPORT_ID_HIDPP_SHORT,4,2      ## @REPORT_ID_HIDPP_SHORT
	.comm	_HIDPP_REPORT_SHORT_LENGTH,4,2  ## @HIDPP_REPORT_SHORT_LENGTH
	.comm	_REPORT_ID_HIDPP_LONG,4,2       ## @REPORT_ID_HIDPP_LONG
	.comm	_HIDPP_REPORT_LONG_LENGTH,4,2   ## @HIDPP_REPORT_LONG_LENGTH
	.comm	_REPORT_ID_HIDPP_VERY_LONG,4,2  ## @REPORT_ID_HIDPP_VERY_LONG
	.comm	_HIDPP_REPORT_VERY_LONG_MAX_LENGTH,4,2 ## @HIDPP_REPORT_VERY_LONG_MAX_LENGTH
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"not enough values in hidpp report %d\n"

	.no_dead_strip	_hidpp_validate_device
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hidpp_validate_device
_hidpp_validate_device:                 ; @hidpp_validate_device
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	bl	_hid_get_drvdata
	mov	x20, x0
Lloh0:
	adrp	x8, _REPORT_ID_HIDPP_SHORT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _REPORT_ID_HIDPP_SHORT@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
	mov	x0, x19
	mov	x1, x22
	bl	_hidpp_get_report_length
	cbz	w0, LBB0_3
; %bb.1:
Lloh3:
	adrp	x8, _HIDPP_REPORT_SHORT_LENGTH@GOTPAGE
Lloh4:
	ldr	x8, [x8, _HIDPP_REPORT_SHORT_LENGTH@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w0, w8
	b.lt	LBB0_9
; %bb.2:
	mov	w21, #1
	b	LBB0_4
LBB0_3:
	mov	w21, #0
LBB0_4:
Lloh6:
	adrp	x8, _REPORT_ID_HIDPP_LONG@GOTPAGE
Lloh7:
	ldr	x8, [x8, _REPORT_ID_HIDPP_LONG@GOTPAGEOFF]
Lloh8:
	ldr	w22, [x8]
	mov	x0, x19
	mov	x1, x22
	bl	_hidpp_get_report_length
Lloh9:
	adrp	x23, _HIDPP_REPORT_LONG_LENGTH@GOTPAGE
Lloh10:
	ldr	x23, [x23, _HIDPP_REPORT_LONG_LENGTH@GOTPAGEOFF]
	cbz	w0, LBB0_7
; %bb.5:
	ldr	w8, [x23]
	cmp	w0, w8
	b.lt	LBB0_9
; %bb.6:
	add	w21, w21, #1
LBB0_7:
Lloh11:
	adrp	x8, _REPORT_ID_HIDPP_VERY_LONG@GOTPAGE
Lloh12:
	ldr	x8, [x8, _REPORT_ID_HIDPP_VERY_LONG@GOTPAGEOFF]
Lloh13:
	ldr	w22, [x8]
	mov	x0, x19
	mov	x1, x22
	bl	_hidpp_get_report_length
	cbz	w0, LBB0_10
; %bb.8:
	ldr	w8, [x23]
Lloh14:
	adrp	x9, _HIDPP_REPORT_VERY_LONG_MAX_LENGTH@GOTPAGE
Lloh15:
	ldr	x9, [x9, _HIDPP_REPORT_VERY_LONG_MAX_LENGTH@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	cmp	w0, w8
	ccmp	w0, w9, #0, ge
	b.le	LBB0_11
LBB0_9:
Lloh17:
	adrp	x1, l_.str@PAGE
Lloh18:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x22
	bl	_hid_warn
	mov	w21, #0
LBB0_10:
	mov	x0, x21
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_11:
	add	w21, w21, #1
	str	w0, [x20]
	b	LBB0_10
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_REPORT_ID_HIDPP_SHORT,4,2      ; @REPORT_ID_HIDPP_SHORT
	.comm	_HIDPP_REPORT_SHORT_LENGTH,4,2  ; @HIDPP_REPORT_SHORT_LENGTH
	.comm	_REPORT_ID_HIDPP_LONG,4,2       ; @REPORT_ID_HIDPP_LONG
	.comm	_HIDPP_REPORT_LONG_LENGTH,4,2   ; @HIDPP_REPORT_LONG_LENGTH
	.comm	_REPORT_ID_HIDPP_VERY_LONG,4,2  ; @REPORT_ID_HIDPP_VERY_LONG
	.comm	_HIDPP_REPORT_VERY_LONG_MAX_LENGTH,4,2 ; @HIDPP_REPORT_VERY_LONG_MAX_LENGTH
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"not enough values in hidpp report %d\n"

	.no_dead_strip	_hidpp_validate_device
.subsections_via_symbols
