	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lineevent_irq_thread
_lineevent_irq_thread:                  ## @lineevent_irq_thread
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %rbx
	leaq	-32(%rbp), %rdi
	xorl	%esi, %esi
	movl	$16, %edx
	callq	_memset
	movq	16(%rbx), %rax
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	xorl	%eax, %eax
	callq	_ktime_get_real_ns
LBB0_2:
	movq	%rax, -24(%rbp)
	movl	(%rbx), %eax
	movq	_GPIOEVENT_REQUEST_RISING_EDGE@GOTPCREL(%rip), %rdx
	movq	_GPIOEVENT_REQUEST_FALLING_EDGE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%eax, (%rdx)
	je	LBB0_6
## %bb.3:
	testl	%eax, %ecx
	je	LBB0_5
## %bb.4:
	movl	12(%rbx), %edi
	callq	_gpiod_get_value_cansleep
	testl	%eax, %eax
	je	LBB0_8
LBB0_5:
	movq	_GPIOEVENT_EVENT_RISING_EDGE@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_6:
	testl	%eax, %ecx
	je	LBB0_7
LBB0_8:
	movq	_GPIOEVENT_EVENT_FALLING_EDGE@GOTPCREL(%rip), %rax
LBB0_9:
	movq	(%rax), %rsi
	movq	%rsi, -32(%rbp)
	leaq	8(%rbx), %rdi
	movq	-24(%rbp), %rdx
	callq	_kfifo_put
	movq	_IRQ_HANDLED@GOTPCREL(%rip), %r14
	testl	%eax, %eax
	je	LBB0_11
## %bb.10:
	addq	$4, %rbx
	movq	_EPOLLIN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_wake_up_poll
	jmp	LBB0_11
LBB0_7:
	movq	_IRQ_NONE@GOTPCREL(%rip), %r14
LBB0_11:
	movl	(%r14), %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GPIOEVENT_REQUEST_RISING_EDGE,4,2 ## @GPIOEVENT_REQUEST_RISING_EDGE
	.comm	_GPIOEVENT_REQUEST_FALLING_EDGE,4,2 ## @GPIOEVENT_REQUEST_FALLING_EDGE
	.comm	_GPIOEVENT_EVENT_RISING_EDGE,8,3 ## @GPIOEVENT_EVENT_RISING_EDGE
	.comm	_GPIOEVENT_EVENT_FALLING_EDGE,8,3 ## @GPIOEVENT_EVENT_FALLING_EDGE
	.comm	_IRQ_NONE,4,2                   ## @IRQ_NONE
	.comm	_EPOLLIN,4,2                    ## @EPOLLIN
	.comm	_IRQ_HANDLED,4,2                ## @IRQ_HANDLED
	.no_dead_strip	_lineevent_irq_thread
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lineevent_irq_thread
_lineevent_irq_thread:                  ; @lineevent_irq_thread
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	mov	x0, sp
	mov	w1, #0
	mov	w2, #16
	bl	_memset
	ldr	x0, [x19, #16]
	cbnz	x0, LBB0_2
; %bb.1:
	bl	_ktime_get_real_ns
LBB0_2:
	str	x0, [sp, #8]
	ldr	w9, [x19]
Lloh0:
	adrp	x8, _GPIOEVENT_REQUEST_RISING_EDGE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GPIOEVENT_REQUEST_RISING_EDGE@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x8]
Lloh3:
	adrp	x8, _GPIOEVENT_REQUEST_FALLING_EDGE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GPIOEVENT_REQUEST_FALLING_EDGE@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	and	w8, w8, w9
	tst	w10, w9
	b.eq	LBB0_6
; %bb.3:
	cbz	w8, LBB0_5
; %bb.4:
	ldr	w0, [x19, #12]
	bl	_gpiod_get_value_cansleep
	cbz	w0, LBB0_7
LBB0_5:
Lloh6:
	adrp	x8, _GPIOEVENT_EVENT_RISING_EDGE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _GPIOEVENT_EVENT_RISING_EDGE@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:
	cbz	w8, LBB0_12
LBB0_7:
Lloh8:
	adrp	x8, _GPIOEVENT_EVENT_FALLING_EDGE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _GPIOEVENT_EVENT_FALLING_EDGE@GOTPAGEOFF]
LBB0_8:
	ldr	x1, [x8]
	str	x1, [sp]
	add	x0, x19, #8
	ldr	x2, [sp, #8]
	bl	_kfifo_put
	cbz	w0, LBB0_10
; %bb.9:
	add	x0, x19, #4
Lloh10:
	adrp	x8, _EPOLLIN@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EPOLLIN@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
	bl	_wake_up_poll
LBB0_10:
Lloh13:
	adrp	x8, _IRQ_HANDLED@GOTPAGE
Lloh14:
	ldr	x8, [x8, _IRQ_HANDLED@GOTPAGEOFF]
LBB0_11:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_12:
Lloh15:
	adrp	x8, _IRQ_NONE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _IRQ_NONE@GOTPAGEOFF]
	b	LBB0_11
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_GPIOEVENT_REQUEST_RISING_EDGE,4,2 ; @GPIOEVENT_REQUEST_RISING_EDGE
	.comm	_GPIOEVENT_REQUEST_FALLING_EDGE,4,2 ; @GPIOEVENT_REQUEST_FALLING_EDGE
	.comm	_GPIOEVENT_EVENT_RISING_EDGE,8,3 ; @GPIOEVENT_EVENT_RISING_EDGE
	.comm	_GPIOEVENT_EVENT_FALLING_EDGE,8,3 ; @GPIOEVENT_EVENT_FALLING_EDGE
	.comm	_IRQ_NONE,4,2                   ; @IRQ_NONE
	.comm	_EPOLLIN,4,2                    ; @EPOLLIN
	.comm	_IRQ_HANDLED,4,2                ; @IRQ_HANDLED
	.no_dead_strip	_lineevent_irq_thread
.subsections_via_symbols
