	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function s6sy761_irq_handler
_s6sy761_irq_handler:                   ## @s6sy761_irq_handler
	.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
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %rbx
	movq	(%rsi), %rcx
	movq	8(%rsi), %rdi
	movq	_S6SY761_READ_ONE_EVENT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_S6SY761_EVENT_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_i2c_smbus_read_i2c_block_data
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movq	(%rbx), %rax
	cmpl	$0, (%rax)
	je	LBB0_7
## %bb.3:
	movq	_S6SY761_MASK_LEFT_EVENTS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r14d
	andl	28(%rax), %r14d
	movq	_S6SY761_EVENT_COUNT@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	(%rax), %r14d
	setge	%dil
	callq	_unlikely
	testq	%rax, %rax
	jne	LBB0_7
## %bb.4:
	testl	%r14d, %r14d
	je	LBB0_6
## %bb.5:
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_s6sy761_read_events
	testl	%eax, %eax
	js	LBB0_1
LBB0_6:
	incl	%r14d
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_s6sy761_handle_events
	jmp	LBB0_7
LBB0_1:
	movq	8(%rbx), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
LBB0_7:
	movq	_IRQ_HANDLED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_S6SY761_READ_ONE_EVENT,4,2     ## @S6SY761_READ_ONE_EVENT
	.comm	_S6SY761_EVENT_SIZE,4,2         ## @S6SY761_EVENT_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to read events\n"

	.comm	_IRQ_HANDLED,4,2                ## @IRQ_HANDLED
	.comm	_S6SY761_MASK_LEFT_EVENTS,4,2   ## @S6SY761_MASK_LEFT_EVENTS
	.comm	_S6SY761_EVENT_COUNT,4,2        ## @S6SY761_EVENT_COUNT
	.no_dead_strip	_s6sy761_irq_handler
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function s6sy761_irq_handler
_s6sy761_irq_handler:                   ; @s6sy761_irq_handler
	.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
	mov	x19, x1
Lloh0:
	adrp	x8, _S6SY761_READ_ONE_EVENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _S6SY761_READ_ONE_EVENT@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _S6SY761_EVENT_SIZE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _S6SY761_EVENT_SIZE@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	ldp	x3, x0, [x19]
	bl	_i2c_smbus_read_i2c_block_data
	tbnz	w0, #31, LBB0_6
; %bb.1:
	ldr	x8, [x19]
	ldr	w9, [x8]
	cbz	w9, LBB0_7
; %bb.2:
	ldr	w8, [x8, #28]
Lloh6:
	adrp	x9, _S6SY761_MASK_LEFT_EVENTS@GOTPAGE
Lloh7:
	ldr	x9, [x9, _S6SY761_MASK_LEFT_EVENTS@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	and	w20, w9, w8
Lloh9:
	adrp	x8, _S6SY761_EVENT_COUNT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _S6SY761_EVENT_COUNT@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	cmp	w20, w8
	cset	w0, ge
	bl	_unlikely
	cbnz	x0, LBB0_7
; %bb.3:
	cbz	w20, LBB0_5
; %bb.4:
	mov	x0, x19
	mov	x1, x20
	bl	_s6sy761_read_events
	tbnz	w0, #31, LBB0_6
LBB0_5:
	add	w1, w20, #1
	mov	x0, x19
	bl	_s6sy761_handle_events
	b	LBB0_7
LBB0_6:
	ldr	x0, [x19, #8]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
LBB0_7:
Lloh14:
	adrp	x8, _IRQ_HANDLED@GOTPAGE
Lloh15:
	ldr	x8, [x8, _IRQ_HANDLED@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_S6SY761_READ_ONE_EVENT,4,2     ; @S6SY761_READ_ONE_EVENT
	.comm	_S6SY761_EVENT_SIZE,4,2         ; @S6SY761_EVENT_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to read events\n"

	.comm	_IRQ_HANDLED,4,2                ; @IRQ_HANDLED
	.comm	_S6SY761_MASK_LEFT_EVENTS,4,2   ; @S6SY761_MASK_LEFT_EVENTS
	.comm	_S6SY761_EVENT_COUNT,4,2        ; @S6SY761_EVENT_COUNT
	.no_dead_strip	_s6sy761_irq_handler
.subsections_via_symbols
