	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function kovaplus_report_to_chrdev
_kovaplus_report_to_chrdev:             ## @kovaplus_report_to_chrdev
	.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
	subq	$48, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	(%rsi), %rcx
	movq	_KOVAPLUS_MOUSE_REPORT_NUMBER_BUTTON@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	jne	LBB0_11
## %bb.1:
	movq	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_PROFILE_2@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	je	LBB0_11
## %bb.2:
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	%rcx, -56(%rbp)
	movq	8(%rdi), %rax
	incq	%rax
	movq	%rax, -24(%rbp)
	movq	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_MACRO@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	je	LBB0_7
## %bb.3:
	movq	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_SHORTCUT@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	je	LBB0_7
## %bb.4:
	movq	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_QUICKLAUNCH@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	je	LBB0_7
## %bb.5:
	movq	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_TIMER@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	je	LBB0_7
## %bb.6:
	xorl	%eax, %eax
	jmp	LBB0_8
LBB0_7:
	movq	16(%rbx), %rax
LBB0_8:
	movq	%rax, -32(%rbp)
	movq	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_CPI@GOTPCREL(%rip), %rdx
	movq	16(%rbx), %rax
	cmpq	(%rdx), %rcx
	jne	LBB0_10
## %bb.9:
	movq	%rax, %rdi
	callq	_kovaplus_convert_event_cpi
LBB0_10:
	movq	%rax, -40(%rbp)
	movl	8(%rbx), %eax
	movl	%eax, -48(%rbp)
	movl	(%r14), %edi
	leaq	-56(%rbp), %rsi
	callq	_roccat_report_event
LBB0_11:
	addq	$48, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_KOVAPLUS_MOUSE_REPORT_NUMBER_BUTTON,8,3 ## @KOVAPLUS_MOUSE_REPORT_NUMBER_BUTTON
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_PROFILE_2,8,3 ## @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_PROFILE_2
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_MACRO,8,3 ## @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_MACRO
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_SHORTCUT,8,3 ## @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_SHORTCUT
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_QUICKLAUNCH,8,3 ## @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_QUICKLAUNCH
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_TIMER,8,3 ## @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_TIMER
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_CPI,8,3 ## @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_CPI
	.no_dead_strip	_kovaplus_report_to_chrdev
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function kovaplus_report_to_chrdev
_kovaplus_report_to_chrdev:             ; @kovaplus_report_to_chrdev
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	ldr	x8, [x1]
Lloh0:
	adrp	x9, _KOVAPLUS_MOUSE_REPORT_NUMBER_BUTTON@GOTPAGE
Lloh1:
	ldr	x9, [x9, _KOVAPLUS_MOUSE_REPORT_NUMBER_BUTTON@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
Lloh3:
	adrp	x10, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_PROFILE_2@GOTPAGE
Lloh4:
	ldr	x10, [x10, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_PROFILE_2@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #4, eq
	b.eq	LBB0_7
; %bb.1:
	mov	x20, x1
	mov	x19, x0
	ldr	x9, [x0, #8]
	add	x9, x9, #1
	str	x8, [sp, #8]
	str	x9, [sp, #40]
Lloh6:
	adrp	x9, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_MACRO@GOTPAGE
Lloh7:
	ldr	x9, [x9, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_MACRO@GOTPAGEOFF]
Lloh8:
	adrp	x10, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_SHORTCUT@GOTPAGE
Lloh9:
	ldr	x10, [x10, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_SHORTCUT@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
Lloh11:
	ldr	x10, [x10]
Lloh12:
	adrp	x11, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_QUICKLAUNCH@GOTPAGE
Lloh13:
	ldr	x11, [x11, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_QUICKLAUNCH@GOTPAGEOFF]
Lloh14:
	adrp	x12, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_TIMER@GOTPAGE
Lloh15:
	ldr	x12, [x12, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_TIMER@GOTPAGEOFF]
Lloh16:
	ldr	x11, [x11]
Lloh17:
	ldr	x12, [x12]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	ccmp	x8, x11, #4, ne
	ccmp	x8, x12, #4, ne
	b.ne	LBB0_3
; %bb.2:
	ldr	x9, [x20, #16]
	b	LBB0_4
LBB0_3:
	mov	x9, #0
LBB0_4:
	str	x9, [sp, #32]
Lloh18:
	adrp	x9, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_CPI@GOTPAGE
Lloh19:
	ldr	x9, [x9, _KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_CPI@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	ldr	x0, [x20, #16]
	cmp	x8, x9
	b.ne	LBB0_6
; %bb.5:
	bl	_kovaplus_convert_event_cpi
LBB0_6:
	str	x0, [sp, #24]
	ldr	w8, [x20, #8]
	str	w8, [sp, #16]
	ldr	w0, [x19]
	add	x1, sp, #8
	bl	_roccat_report_event
LBB0_7:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh16
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh10
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_KOVAPLUS_MOUSE_REPORT_NUMBER_BUTTON,8,3 ; @KOVAPLUS_MOUSE_REPORT_NUMBER_BUTTON
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_PROFILE_2,8,3 ; @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_PROFILE_2
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_MACRO,8,3 ; @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_MACRO
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_SHORTCUT,8,3 ; @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_SHORTCUT
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_QUICKLAUNCH,8,3 ; @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_QUICKLAUNCH
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_TIMER,8,3 ; @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_TIMER
	.comm	_KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_CPI,8,3 ; @KOVAPLUS_MOUSE_REPORT_BUTTON_TYPE_CPI
	.no_dead_strip	_kovaplus_report_to_chrdev
.subsections_via_symbols
