	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mtk_aes_irq
_mtk_aes_irq:                           ## @mtk_aes_irq
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	16(%rsi), %r14
	movl	8(%rsi), %edi
	callq	_RDR_STAT
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_mtk_aes_read
	movl	%eax, %r15d
	movl	8(%rbx), %edi
	callq	_RDR_STAT
	movq	%r14, %rdi
	movl	%eax, %esi
	movl	%r15d, %edx
	callq	_mtk_aes_write
	movq	_AES_FLAGS_BUSY@GOTPCREL(%rip), %rax
	movl	(%rbx), %edi
	andl	(%rax), %edi
	callq	_likely
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movl	8(%rbx), %edi
	callq	_RDR_PROC_COUNT
	movq	_MTK_CNT_RST@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_mtk_aes_write
	movl	8(%rbx), %edi
	callq	_RDR_THRESH
	movq	_MTK_RDR_PROC_THRESH@GOTPCREL(%rip), %rcx
	movq	_MTK_RDR_PROC_MODE@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_mtk_aes_write
	addq	$4, %rbx
	movq	%rbx, %rdi
	callq	_tasklet_schedule
	jmp	LBB0_3
LBB0_2:
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_warn
LBB0_3:
	movq	_IRQ_HANDLED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AES_FLAGS_BUSY,4,2             ## @AES_FLAGS_BUSY
	.comm	_MTK_CNT_RST,4,2                ## @MTK_CNT_RST
	.comm	_MTK_RDR_PROC_THRESH,4,2        ## @MTK_RDR_PROC_THRESH
	.comm	_MTK_RDR_PROC_MODE,4,2          ## @MTK_RDR_PROC_MODE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"AES interrupt when no active requests.\n"

	.comm	_IRQ_HANDLED,4,2                ## @IRQ_HANDLED
	.no_dead_strip	_mtk_aes_irq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mtk_aes_irq
_mtk_aes_irq:                           ; @mtk_aes_irq
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x1
	ldr	x20, [x1, #16]
	ldr	w0, [x1, #8]
	bl	_RDR_STAT
	mov	x1, x0
	mov	x0, x20
	bl	_mtk_aes_read
	mov	x21, x0
	ldr	w0, [x19, #8]
	bl	_RDR_STAT
	mov	x1, x0
	mov	x0, x20
	mov	x2, x21
	bl	_mtk_aes_write
Lloh0:
	adrp	x8, _AES_FLAGS_BUSY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AES_FLAGS_BUSY@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x19]
	and	w0, w9, w8
	bl	_likely
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w0, [x19, #8]
	bl	_RDR_PROC_COUNT
	mov	x1, x0
Lloh3:
	adrp	x8, _MTK_CNT_RST@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MTK_CNT_RST@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_mtk_aes_write
	ldr	w0, [x19, #8]
	bl	_RDR_THRESH
	mov	x1, x0
Lloh6:
	adrp	x8, _MTK_RDR_PROC_THRESH@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MTK_RDR_PROC_THRESH@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
Lloh9:
	adrp	x9, _MTK_RDR_PROC_MODE@GOTPAGE
Lloh10:
	ldr	x9, [x9, _MTK_RDR_PROC_MODE@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	x0, x20
	bl	_mtk_aes_write
	add	x0, x19, #4
	bl	_tasklet_schedule
	b	LBB0_3
LBB0_2:
	ldr	w0, [x20]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_warn
LBB0_3:
Lloh14:
	adrp	x8, _IRQ_HANDLED@GOTPAGE
Lloh15:
	ldr	x8, [x8, _IRQ_HANDLED@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_AES_FLAGS_BUSY,4,2             ; @AES_FLAGS_BUSY
	.comm	_MTK_CNT_RST,4,2                ; @MTK_CNT_RST
	.comm	_MTK_RDR_PROC_THRESH,4,2        ; @MTK_RDR_PROC_THRESH
	.comm	_MTK_RDR_PROC_MODE,4,2          ; @MTK_RDR_PROC_MODE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"AES interrupt when no active requests.\n"

	.comm	_IRQ_HANDLED,4,2                ; @IRQ_HANDLED
	.no_dead_strip	_mtk_aes_irq
.subsections_via_symbols
