	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wacom_update_led
_wacom_update_led:                      ## @wacom_update_led
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r14d
	movq	%rdi, %rbx
	movq	16(%rdi), %rax
	movq	_WACOM_24HD@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_1
## %bb.8:
	movq	%rbx, %rdi
	movl	%edx, %esi
	movl	%r14d, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_wacom_24hd_update_leds         ## TAILCALL
LBB0_1:
	movq	%rbx, %rdi
	movl	%r14d, %ecx
	callq	_wacom_is_led_toggled
	movl	%eax, %r13d
	movq	8(%rbx), %rax
	movslq	%r14d, %rsi
	movl	(%rax,%rsi,4), %r12d
	movq	%rbx, %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	movl	%r12d, %edx
	callq	_wacom_led_find
	testq	%rax, %rax
	je	LBB0_9
## %bb.2:
	movq	%rax, %r15
	testl	%r13d, %r13d
	je	LBB0_3
## %bb.4:
	cmpl	$0, (%r15)
	jne	LBB0_7
## %bb.5:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_wacom_led_next
	testq	%rax, %rax
	je	LBB0_10
## %bb.6:
	cmpq	%r15, %rax
	je	LBB0_7
## %bb.11:
	movl	$1, (%rax)
	movq	%rax, %rbx
	addq	$4, %rbx
	movq	%rax, %rdi
	callq	_wacom_leds_brightness_get
	movq	%rbx, %rdi
	movl	%eax, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_led_trigger_event              ## TAILCALL
LBB0_9:
	movl	(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	movl	%r12d, %edx
	movl	%r14d, %ecx
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_hid_err                        ## TAILCALL
LBB0_3:
	movl	$0, (%r15)
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	movl	(%rbx), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%r14d, %edx
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_hid_err                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_WACOM_24HD,8,3                 ## @WACOM_24HD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"can't find current LED %d in group %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"can't find next LED in group %d\n"

	.no_dead_strip	_wacom_update_led
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wacom_update_led
_wacom_update_led:                      ; @wacom_update_led
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x3
	mov	x20, x0
	ldr	x8, [x0, #16]
Lloh0:
	adrp	x9, _WACOM_24HD@GOTPAGE
Lloh1:
	ldr	x9, [x9, _WACOM_24HD@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x20
	mov	x1, x2
	mov	x2, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	b	_wacom_24hd_update_leds
LBB0_2:
	mov	x0, x20
	mov	x3, x19
	bl	_wacom_is_led_toggled
	mov	x23, x0
	ldr	x8, [x20, #8]
	ldr	w22, [x8, w19, sxtw #2]
	mov	x0, x20
	mov	x1, x19
	mov	x2, x22
	bl	_wacom_led_find
	cbz	x0, LBB0_8
; %bb.3:
	mov	x21, x0
	cbz	w23, LBB0_9
; %bb.4:
	ldr	w8, [x21]
	cbnz	w8, LBB0_10
; %bb.5:
	mov	x0, x20
	mov	x1, x21
	bl	_wacom_led_next
	cbz	x0, LBB0_11
; %bb.6:
	cmp	x0, x21
	b.eq	LBB0_10
; %bb.7:
	mov	w8, #1
	mov	x19, x0
	str	w8, [x19], #4
	bl	_wacom_leds_brightness_get
	mov	x1, x0
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	b	_led_trigger_event
LBB0_8:
	ldr	w0, [x20]
	str	x19, [sp]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x22
	bl	_hid_err
	b	LBB0_10
LBB0_9:
	str	wzr, [x21]
LBB0_10:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_11:
	ldr	w0, [x20]
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	b	_hid_err
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_WACOM_24HD,8,3                 ; @WACOM_24HD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"can't find current LED %d in group %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"can't find next LED in group %d\n"

	.no_dead_strip	_wacom_update_led
.subsections_via_symbols
