	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pcap_keys_probe
_pcap_keys_probe:                       ## @pcap_keys_probe
	.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
	movq	%rdi, %r12
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16, %edi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_9
## %bb.1:
	movq	%rax, %r14
	movl	(%r12), %edi
	callq	_dev_get_drvdata
	movl	%eax, (%r14)
	xorl	%eax, %eax
	callq	_input_allocate_device
	testq	%rax, %rax
	je	LBB0_8
## %bb.2:
	movq	%rax, %r15
	movq	%rax, 8(%r14)
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_platform_set_drvdata
	movl	4(%r12), %eax
	movl	%eax, 28(%r15)
	leaq	L_.str(%rip), %rax
	movq	%rax, (%r15)
	movq	_BUS_HOST@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%r15)
	movq	%r12, 16(%r15)
	movq	_EV_KEY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	12(%r15), %esi
	callq	___set_bit
	movq	_KEY_POWER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	8(%r15), %esi
	callq	___set_bit
	movq	_KEY_HP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	8(%r15), %esi
	callq	___set_bit
	movq	%r15, %rdi
	callq	_input_register_device
	testl	%eax, %eax
	je	LBB0_3
## %bb.7:
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_input_free_device
	jmp	LBB0_8
LBB0_3:
	movl	(%r14), %edi
	movq	_PCAP_IRQ_ONOFF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_pcap_to_irq
	movq	_pcap_keys_handler@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	leaq	L_.str.1(%rip), %rcx
	xorl	%ebx, %ebx
	movl	%eax, %edi
	xorl	%edx, %edx
	movq	%r14, %r8
	callq	_request_irq
	movl	%eax, %r12d
	testl	%eax, %eax
	jne	LBB0_6
## %bb.4:
	movl	(%r14), %edi
	movq	_PCAP_IRQ_MIC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_pcap_to_irq
	movl	(%r13), %esi
	leaq	L_.str.2(%rip), %rcx
	movl	%eax, %edi
	xorl	%edx, %edx
	movq	%r14, %r8
	callq	_request_irq
	testl	%eax, %eax
	je	LBB0_9
## %bb.5:
	movl	%eax, %r12d
	movl	(%r14), %edi
	movq	_PCAP_IRQ_ONOFF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_pcap_to_irq
	movl	%eax, %edi
	movq	%r14, %rsi
	callq	_free_irq
LBB0_6:
	movq	%r15, %rdi
	callq	_input_unregister_device
	movl	%r12d, %ebx
LBB0_8:
	movq	%r14, %rdi
	callq	_kfree
LBB0_9:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"pcap-keys/input0"

	.comm	_BUS_HOST,4,2                   ## @BUS_HOST
	.comm	_EV_KEY,4,2                     ## @EV_KEY
	.comm	_KEY_POWER,4,2                  ## @KEY_POWER
	.comm	_KEY_HP,4,2                     ## @KEY_HP
	.comm	_PCAP_IRQ_ONOFF,4,2             ## @PCAP_IRQ_ONOFF
	.comm	_pcap_keys_handler,4,2          ## @pcap_keys_handler
L_.str.1:                               ## @.str.1
	.asciz	"Power key"

	.comm	_PCAP_IRQ_MIC,4,2               ## @PCAP_IRQ_MIC
L_.str.2:                               ## @.str.2
	.asciz	"Headphone button"

	.no_dead_strip	_pcap_keys_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pcap_keys_probe
_pcap_keys_probe:                       ; @pcap_keys_probe
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x22, x0
Lloh0:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w21, w8
Lloh3:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	w0, #16
	bl	_kmalloc
	cbz	x0, LBB0_9
; %bb.1:
	mov	x19, x0
	ldr	w0, [x22]
	bl	_dev_get_drvdata
	str	w0, [x19]
	bl	_input_allocate_device
	cbz	x0, LBB0_8
; %bb.2:
	mov	x20, x0
	str	x0, [x19, #8]
	mov	x0, x22
	mov	x1, x19
	bl	_platform_set_drvdata
Lloh6:
	adrp	x8, l_.str@PAGE
Lloh7:
	add	x8, x8, l_.str@PAGEOFF
	ldr	w9, [x22, #4]
	str	x8, [x20]
Lloh8:
	adrp	x8, _BUS_HOST@GOTPAGE
Lloh9:
	ldr	x8, [x8, _BUS_HOST@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	stp	w8, w9, [x20, #24]
	str	x22, [x20, #16]
Lloh11:
	adrp	x8, _EV_KEY@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EV_KEY@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	ldr	w1, [x20, #12]
	bl	___set_bit
Lloh14:
	adrp	x8, _KEY_POWER@GOTPAGE
Lloh15:
	ldr	x8, [x8, _KEY_POWER@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	ldr	w1, [x20, #8]
	bl	___set_bit
Lloh17:
	adrp	x8, _KEY_HP@GOTPAGE
Lloh18:
	ldr	x8, [x8, _KEY_HP@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
	ldr	w1, [x20, #8]
	bl	___set_bit
	mov	x0, x20
	bl	_input_register_device
	cbz	w0, LBB0_4
; %bb.3:
	mov	x21, x0
	mov	x0, x20
	bl	_input_free_device
	b	LBB0_8
LBB0_4:
	ldr	w0, [x19]
Lloh20:
	adrp	x22, _PCAP_IRQ_ONOFF@GOTPAGE
Lloh21:
	ldr	x22, [x22, _PCAP_IRQ_ONOFF@GOTPAGEOFF]
	ldr	w1, [x22]
	bl	_pcap_to_irq
Lloh22:
	adrp	x23, _pcap_keys_handler@GOTPAGE
Lloh23:
	ldr	x23, [x23, _pcap_keys_handler@GOTPAGEOFF]
	ldr	w1, [x23]
Lloh24:
	adrp	x3, l_.str.1@PAGE
Lloh25:
	add	x3, x3, l_.str.1@PAGEOFF
	mov	w2, #0
	mov	x4, x19
	bl	_request_irq
	mov	x21, x0
	cbnz	w0, LBB0_7
; %bb.5:
	ldr	w0, [x19]
Lloh26:
	adrp	x8, _PCAP_IRQ_MIC@GOTPAGE
Lloh27:
	ldr	x8, [x8, _PCAP_IRQ_MIC@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
	bl	_pcap_to_irq
	ldr	w1, [x23]
Lloh29:
	adrp	x3, l_.str.2@PAGE
Lloh30:
	add	x3, x3, l_.str.2@PAGEOFF
	mov	w2, #0
	mov	x4, x19
	bl	_request_irq
	mov	x21, x0
	cbz	w0, LBB0_9
; %bb.6:
	ldr	w0, [x19]
	ldr	w1, [x22]
	bl	_pcap_to_irq
	mov	x1, x19
	bl	_free_irq
LBB0_7:
	mov	x0, x20
	bl	_input_unregister_device
LBB0_8:
	mov	x0, x19
	bl	_kfree
LBB0_9:
	mov	x0, x21
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"pcap-keys/input0"

	.comm	_BUS_HOST,4,2                   ; @BUS_HOST
	.comm	_EV_KEY,4,2                     ; @EV_KEY
	.comm	_KEY_POWER,4,2                  ; @KEY_POWER
	.comm	_KEY_HP,4,2                     ; @KEY_HP
	.comm	_PCAP_IRQ_ONOFF,4,2             ; @PCAP_IRQ_ONOFF
	.comm	_pcap_keys_handler,4,2          ; @pcap_keys_handler
l_.str.1:                               ; @.str.1
	.asciz	"Power key"

	.comm	_PCAP_IRQ_MIC,4,2               ; @PCAP_IRQ_MIC
l_.str.2:                               ; @.str.2
	.asciz	"Headphone button"

	.no_dead_strip	_pcap_keys_probe
.subsections_via_symbols
