	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hotkey_write
_hotkey_write:                          ## @hotkey_write
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, -56(%rbp)
	movq	_tp_features@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_1
## %bb.3:
	movq	_hotkey_mutex@GOTPCREL(%rip), %rdi
	callq	_mutex_lock_killable
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	_ERESTARTSYS@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_1:
	movq	_ENODEV@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_21
LBB0_5:
	movq	_hotkey_user_mask@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	leaq	-56(%rbp), %rdi
	callq	_next_cmd
	testq	%rax, %rax
	je	LBB0_15
## %bb.6:
	movq	%rax, %r13
	movl	$0, -48(%rbp)                   ## 4-byte Folded Spill
	leaq	L_.str(%rip), %r15
	leaq	-56(%rbp), %r14
	leaq	L_.str.1(%rip), %r12
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_7 Depth=1
	movl	$1, %edi
	callq	_hotkey_enabledisable_warn
LBB0_13:                                ##   in Loop: Header=BB0_7 Depth=1
	movq	%r14, %rdi
	callq	_next_cmd
	movq	%rax, %r13
	testq	%rax, %rax
	je	LBB0_14
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	movq	%r15, %rsi
	callq	_strlencmp
	testq	%rax, %rax
	je	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	%r13, %rdi
	movq	%r12, %rsi
	callq	_strlencmp
	testq	%rax, %rax
	je	LBB0_10
## %bb.11:                              ##   in Loop: Header=BB0_7 Depth=1
	movq	%r13, %rdi
	leaq	L_.str.2(%rip), %rsi
	callq	_strlencmp
	testq	%rax, %rax
	je	LBB0_12
## %bb.16:                              ##   in Loop: Header=BB0_7 Depth=1
	movq	%r12, %rbx
	movq	%r13, %rdi
	leaq	L_.str.3(%rip), %rsi
	leaq	-44(%rbp), %r12
	movq	%r12, %rdx
	callq	_sscanf
	cmpl	$1, %eax
	jne	LBB0_18
## %bb.17:                              ##   in Loop: Header=BB0_7 Depth=1
	movq	%rbx, %r12
	jmp	LBB0_13
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_7 Depth=1
	xorl	%edi, %edi
	callq	_hotkey_enabledisable_warn
	xorl	%ecx, %ecx
	movq	_EPERM@GOTPCREL(%rip), %rax
	subl	(%rax), %ecx
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	jmp	LBB0_13
LBB0_12:                                ##   in Loop: Header=BB0_7 Depth=1
	movq	_hotkey_source_mask@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_hotkey_all_mask@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movq	_hotkey_reserved_mask@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	notl	%ecx
	andl	%eax, %ecx
	movl	%ecx, -44(%rbp)
	jmp	LBB0_13
LBB0_18:                                ##   in Loop: Header=BB0_7 Depth=1
	movq	%r13, %rdi
	leaq	L_.str.4(%rip), %rsi
	movq	%r12, %rdx
	callq	_sscanf
	cmpl	$1, %eax
	movq	%rbx, %r12
	je	LBB0_13
## %bb.19:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_20
LBB0_14:
	movl	-48(%rbp), %ebx                 ## 4-byte Reload
	testl	%ebx, %ebx
	jne	LBB0_20
LBB0_15:
	movl	-44(%rbp), %edx
	leaq	L_.str.5(%rip), %rdi
	leaq	L_.str.6(%rip), %rsi
	callq	_tpacpi_disclose_usertask
	movl	-44(%rbp), %edi
	callq	_hotkey_user_mask_set
	movl	%eax, %ebx
LBB0_20:
	movq	_hotkey_mutex@GOTPCREL(%rip), %rdi
	callq	_mutex_unlock
LBB0_21:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_tp_features,4,2                ## @tp_features
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_hotkey_mutex,4,2               ## @hotkey_mutex
	.comm	_ERESTARTSYS,4,2                ## @ERESTARTSYS
	.comm	_hotkey_user_mask,4,2           ## @hotkey_user_mask
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"enable"

L_.str.1:                               ## @.str.1
	.asciz	"disable"

	.comm	_EPERM,4,2                      ## @EPERM
L_.str.2:                               ## @.str.2
	.asciz	"reset"

	.comm	_hotkey_all_mask,4,2            ## @hotkey_all_mask
	.comm	_hotkey_source_mask,4,2         ## @hotkey_source_mask
	.comm	_hotkey_reserved_mask,4,2       ## @hotkey_reserved_mask
L_.str.3:                               ## @.str.3
	.asciz	"0x%x"

L_.str.4:                               ## @.str.4
	.asciz	"%x"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.5:                               ## @.str.5
	.asciz	"procfs hotkey"

L_.str.6:                               ## @.str.6
	.asciz	"set mask to 0x%08x\n"

	.no_dead_strip	_hotkey_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hotkey_write
_hotkey_write:                          ; @hotkey_write
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	str	x0, [sp, #8]
Lloh0:
	adrp	x8, _tp_features@GOTPAGE
Lloh1:
	ldr	x8, [x8, _tp_features@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cbz	w8, LBB0_3
; %bb.1:
Lloh3:
	adrp	x0, _hotkey_mutex@GOTPAGE
Lloh4:
	ldr	x0, [x0, _hotkey_mutex@GOTPAGEOFF]
	bl	_mutex_lock_killable
	cbz	x0, LBB0_5
; %bb.2:
Lloh5:
	adrp	x8, _ERESTARTSYS@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ERESTARTSYS@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:
Lloh7:
	adrp	x8, _ENODEV@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	neg	w19, w8
	b	LBB0_19
LBB0_5:
Lloh9:
	adrp	x8, _hotkey_user_mask@GOTPAGE
Lloh10:
	ldr	x8, [x8, _hotkey_user_mask@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	str	w8, [sp, #4]
	add	x0, sp, #8
	bl	_next_cmd
	cbz	x0, LBB0_17
; %bb.6:
	mov	x25, x0
	mov	w19, #0
Lloh12:
	adrp	x20, l_.str@PAGE
Lloh13:
	add	x20, x20, l_.str@PAGEOFF
Lloh14:
	adrp	x21, l_.str.1@PAGE
Lloh15:
	add	x21, x21, l_.str.1@PAGEOFF
Lloh16:
	adrp	x26, _EPERM@GOTPAGE
Lloh17:
	ldr	x26, [x26, _EPERM@GOTPAGEOFF]
Lloh18:
	adrp	x22, l_.str.2@PAGE
Lloh19:
	add	x22, x22, l_.str.2@PAGEOFF
Lloh20:
	adrp	x27, _hotkey_all_mask@GOTPAGE
Lloh21:
	ldr	x27, [x27, _hotkey_all_mask@GOTPAGEOFF]
Lloh22:
	adrp	x28, _hotkey_source_mask@GOTPAGE
Lloh23:
	ldr	x28, [x28, _hotkey_source_mask@GOTPAGEOFF]
Lloh24:
	adrp	x24, _hotkey_reserved_mask@GOTPAGE
Lloh25:
	ldr	x24, [x24, _hotkey_reserved_mask@GOTPAGEOFF]
Lloh26:
	adrp	x23, l_.str.3@PAGE
Lloh27:
	add	x23, x23, l_.str.3@PAGEOFF
	b	LBB0_9
LBB0_7:                                 ;   in Loop: Header=BB0_9 Depth=1
	mov	w0, #1
	bl	_hotkey_enabledisable_warn
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	add	x0, sp, #8
	bl	_next_cmd
	mov	x25, x0
	cbz	x0, LBB0_16
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x25
	mov	x1, x20
	bl	_strlencmp
	cbz	x0, LBB0_7
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x25
	mov	x1, x21
	bl	_strlencmp
	cbz	x0, LBB0_14
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x25
	mov	x1, x22
	bl	_strlencmp
	cbz	x0, LBB0_15
; %bb.12:                               ;   in Loop: Header=BB0_9 Depth=1
	add	x2, sp, #4
	mov	x0, x25
	mov	x1, x23
	bl	_sscanf
	cmp	w0, #1
	b.eq	LBB0_8
; %bb.13:                               ;   in Loop: Header=BB0_9 Depth=1
	add	x2, sp, #4
	mov	x0, x25
Lloh28:
	adrp	x1, l_.str.4@PAGE
Lloh29:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_sscanf
	cmp	w0, #1
	b.eq	LBB0_8
	b	LBB0_20
LBB0_14:                                ;   in Loop: Header=BB0_9 Depth=1
	bl	_hotkey_enabledisable_warn
	ldr	w8, [x26]
	neg	w19, w8
	b	LBB0_8
LBB0_15:                                ;   in Loop: Header=BB0_9 Depth=1
	ldr	w8, [x27]
	ldr	w9, [x28]
	orr	w8, w9, w8
	ldr	w9, [x24]
	bic	w8, w8, w9
	str	w8, [sp, #4]
	b	LBB0_8
LBB0_16:
	cbnz	w19, LBB0_18
LBB0_17:
	ldr	w2, [sp, #4]
Lloh30:
	adrp	x0, l_.str.5@PAGE
Lloh31:
	add	x0, x0, l_.str.5@PAGEOFF
Lloh32:
	adrp	x1, l_.str.6@PAGE
Lloh33:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_tpacpi_disclose_usertask
	ldr	w0, [sp, #4]
	bl	_hotkey_user_mask_set
	mov	x19, x0
LBB0_18:
Lloh34:
	adrp	x0, _hotkey_mutex@GOTPAGE
Lloh35:
	ldr	x0, [x0, _hotkey_mutex@GOTPAGEOFF]
	bl	_mutex_unlock
LBB0_19:
	mov	x0, x19
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_20:
Lloh36:
	adrp	x8, _EINVAL@GOTPAGE
Lloh37:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh38:
	ldr	w8, [x8]
	neg	w19, w8
	b	LBB0_18
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.comm	_tp_features,4,2                ; @tp_features
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_hotkey_mutex,4,2               ; @hotkey_mutex
	.comm	_ERESTARTSYS,4,2                ; @ERESTARTSYS
	.comm	_hotkey_user_mask,4,2           ; @hotkey_user_mask
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"enable"

l_.str.1:                               ; @.str.1
	.asciz	"disable"

	.comm	_EPERM,4,2                      ; @EPERM
l_.str.2:                               ; @.str.2
	.asciz	"reset"

	.comm	_hotkey_all_mask,4,2            ; @hotkey_all_mask
	.comm	_hotkey_source_mask,4,2         ; @hotkey_source_mask
	.comm	_hotkey_reserved_mask,4,2       ; @hotkey_reserved_mask
l_.str.3:                               ; @.str.3
	.asciz	"0x%x"

l_.str.4:                               ; @.str.4
	.asciz	"%x"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.5:                               ; @.str.5
	.asciz	"procfs hotkey"

l_.str.6:                               ; @.str.6
	.asciz	"set mask to 0x%08x\n"

	.no_dead_strip	_hotkey_write
.subsections_via_symbols
