	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mousedev_reserve_minor
_mousedev_reserve_minor:                ## @mousedev_reserve_minor
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	testl	%edi, %edi
	je	LBB0_3
## %bb.1:
	movq	_MOUSEDEV_MIX@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %esi
	xorl	%edx, %edx
	callq	_input_get_new_minor
	movl	%eax, %ebx
	testl	%eax, %eax
	jns	LBB0_6
## %bb.2:
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_5
LBB0_3:
	movq	_MOUSEDEV_MINOR_BASE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_MOUSEDEV_MINORS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edx
	callq	_input_get_new_minor
	movl	%eax, %ebx
	testl	%eax, %eax
	jns	LBB0_6
## %bb.4:
	leaq	L_.str.1(%rip), %rdi
LBB0_5:
	movl	%ebx, %esi
	callq	_pr_err
LBB0_6:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MOUSEDEV_MIX,4,2               ## @MOUSEDEV_MIX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to reserve mixdev minor: %d\n"

	.comm	_MOUSEDEV_MINOR_BASE,4,2        ## @MOUSEDEV_MINOR_BASE
	.comm	_MOUSEDEV_MINORS,4,2            ## @MOUSEDEV_MINORS
L_.str.1:                               ## @.str.1
	.asciz	"failed to reserve new minor: %d\n"

	.no_dead_strip	_mousedev_reserve_minor
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mousedev_reserve_minor
_mousedev_reserve_minor:                ; @mousedev_reserve_minor
	.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
	cbz	w0, LBB0_3
; %bb.1:
Lloh0:
	adrp	x8, _MOUSEDEV_MIX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MOUSEDEV_MIX@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	mov	w1, #1
	mov	w2, #0
	bl	_input_get_new_minor
	mov	x19, x0
	tbz	w0, #31, LBB0_6
; %bb.2:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_5
LBB0_3:
Lloh5:
	adrp	x8, _MOUSEDEV_MINOR_BASE@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MOUSEDEV_MINOR_BASE@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
Lloh8:
	adrp	x8, _MOUSEDEV_MINORS@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MOUSEDEV_MINORS@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	w2, #1
	bl	_input_get_new_minor
	mov	x19, x0
	tbz	w0, #31, LBB0_6
; %bb.4:
Lloh11:
	adrp	x0, l_.str.1@PAGE
Lloh12:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_5:
	mov	x1, x19
	bl	_pr_err
LBB0_6:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_MOUSEDEV_MIX,4,2               ; @MOUSEDEV_MIX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to reserve mixdev minor: %d\n"

	.comm	_MOUSEDEV_MINOR_BASE,4,2        ; @MOUSEDEV_MINOR_BASE
	.comm	_MOUSEDEV_MINORS,4,2            ; @MOUSEDEV_MINORS
l_.str.1:                               ; @.str.1
	.asciz	"failed to reserve new minor: %d\n"

	.no_dead_strip	_mousedev_reserve_minor
.subsections_via_symbols
