	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_uinput_kbd_status_changed      ## -- Begin function uinput_kbd_status_changed
	.p2align	4, 0x90
_uinput_kbd_status_changed:             ## @uinput_kbd_status_changed
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %ebx
	movq	%rsi, %r14
	movq	%rdi, %r15
	xorl	%edi, %edi
	testq	%r15, %r15
	setne	%dil
	callq	_assert
	movq	(%r15), %rdi
	shrq	$63, %rdi
	xorl	$1, %edi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_assert
	xorl	%edi, %edi
	cmpl	$12, %ebx
	sete	%dil
	callq	_assert
	leaq	-48(%rbp), %rdi
	movq	%r14, %rsi
	movl	$12, %edx
	callq	_memcpy
	cmpl	$129, -48(%rbp)
	jne	LBB0_7
## %bb.1:
	movq	(%r15), %rdi
	movq	_KDGETLED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-36(%rbp), %rdx
	xorl	%eax, %eax
	callq	_ioctl
	movl	-36(%rbp), %r14d
	movq	_led_codes@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	callq	_nitems
	testq	%rax, %rax
	je	LBB0_7
## %bb.2:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r12), %rdi
	movl	(%rdi,%rbx,4), %eax
	cmpl	-40(%rbp), %eax
	je	LBB0_4
## %bb.6:                               ##   in Loop: Header=BB0_3 Depth=1
	incq	%rbx
	callq	_nitems
	cmpq	%rax, %rbx
	jb	LBB0_3
	jmp	LBB0_7
LBB0_4:
	movl	%r14d, %eax
	btsl	%ebx, %eax
	btrl	%ebx, %r14d
	cmpl	$0, -44(%rbp)
	cmovnel	%eax, %r14d
	cmpl	-36(%rbp), %r14d
	je	LBB0_7
## %bb.5:
	movq	(%r15), %rdi
	movq	_KDSETLED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_ioctl
LBB0_7:
	xorl	%eax, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_KDGETLED,4,2                   ## @KDGETLED
	.comm	_led_codes,8,3                  ## @led_codes
	.comm	_KDSETLED,4,2                   ## @KDSETLED
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_uinput_kbd_status_changed      ; -- Begin function uinput_kbd_status_changed
	.p2align	2
_uinput_kbd_status_changed:             ; @uinput_kbd_status_changed
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
	cmp	x0, #0
	cset	w0, ne
	bl	_assert
	ldr	x8, [x19]
	lsr	x8, x8, #63
	eor	w0, w8, #0x1
	bl	_assert
	cmp	w20, #12
	cset	w0, eq
	bl	_assert
	add	x0, sp, #16
	mov	x1, x21
	mov	w2, #12
	bl	_memcpy
	ldr	w8, [sp, #16]
	cmp	w8, #129
	b.ne	LBB0_7
; %bb.1:
	ldr	x0, [x19]
Lloh0:
	adrp	x8, _KDGETLED@GOTPAGE
Lloh1:
	ldr	x8, [x8, _KDGETLED@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x8, sp, #12
	str	x8, [sp]
	bl	_ioctl
	ldr	w20, [sp, #12]
Lloh3:
	adrp	x21, _led_codes@GOTPAGE
Lloh4:
	ldr	x21, [x21, _led_codes@GOTPAGEOFF]
	ldr	x0, [x21]
	bl	_nitems
	cbz	x0, LBB0_7
; %bb.2:
	mov	x22, #0
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x21]
	ldr	w8, [x0, x22, lsl #2]
	ldr	w9, [sp, #24]
	cmp	w8, w9
	b.eq	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x22, x22, #1
	bl	_nitems
	cmp	x22, x0
	b.lo	LBB0_3
	b	LBB0_7
LBB0_5:
	ldr	w8, [sp, #20]
	mov	w9, #1
	lsl	w9, w9, w22
	orr	w10, w9, w20
	bic	w9, w20, w9
	cmp	w8, #0
	csel	w8, w9, w10, eq
	ldr	w9, [sp, #12]
	cmp	w8, w9
	b.eq	LBB0_7
; %bb.6:
	ldr	x0, [x19]
Lloh5:
	adrp	x9, _KDSETLED@GOTPAGE
Lloh6:
	ldr	x9, [x9, _KDSETLED@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x9]
	str	x8, [sp]
	bl	_ioctl
LBB0_7:
	mov	w0, #0
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_KDGETLED,4,2                   ; @KDGETLED
	.comm	_led_codes,8,3                  ; @led_codes
	.comm	_KDSETLED,4,2                   ; @KDSETLED
.subsections_via_symbols
