	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function r852_irq
_r852_irq:                              ## @r852_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	%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	%rsi, %r14
	movq	_IRQ_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	leaq	24(%rsi), %r15
	movq	%r15, %rdi
	callq	_spin_lock_irqsave
	movq	_R852_CARD_IRQ_STA@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r14, %rdi
	callq	_r852_read_reg
	movl	%eax, %r13d
	movl	(%rbx), %esi
	movq	%r14, %rdi
	movl	%eax, %edx
	callq	_r852_write_reg
	movq	_R852_CARD_IRQ_INSERT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_R852_CARD_IRQ_REMOVE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	%eax, %ecx
	testl	%r13d, %ecx
	je	LBB0_3
## %bb.1:
	movq	_IRQ_HANDLED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	xorl	%ecx, %ecx
	testl	%r13d, %eax
	setne	%cl
	movl	%ecx, (%r14)
	movl	4(%r14), %edi
	callq	_WARN_ON
	movq	%r14, %rdi
	callq	_r852_disable_irqs
	cmpl	$0, 4(%r14)
	jne	LBB0_22
## %bb.2:
	movl	$1, 4(%r14)
	movl	36(%r14), %r12d
	addq	$32, %r14
	movl	$100, %edi
	callq	_msecs_to_jiffies
	movl	%r12d, %edi
	movq	%r14, %rsi
	movl	%eax, %edx
	callq	_queue_delayed_work
	jmp	LBB0_22
LBB0_3:
	movl	%r12d, -44(%rbp)                ## 4-byte Spill
	movq	_R852_DMA_IRQ_STA@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r14, %rdi
	callq	_r852_read_reg_dword
	movl	%eax, %r12d
	movl	(%rbx), %esi
	movq	%r14, %rdi
	movl	%eax, %edx
	callq	_r852_write_reg_dword
	movq	_R852_DMA_IRQ_MASK@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	je	LBB0_18
## %bb.4:
	movq	_IRQ_HANDLED@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_R852_DMA_IRQ_ERROR@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	je	LBB0_6
## %bb.5:
	leaq	L_.str(%rip), %rdi
	xorl	%r12d, %r12d
	xorl	%eax, %eax
	callq	_dbg
	movq	_EIO@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
	movq	%r14, %rdi
	movl	%r12d, %esi
LBB0_17:
	callq	_r852_dma_done
	addq	$28, %r14
	movq	%r14, %rdi
	callq	_complete
	jmp	LBB0_22
LBB0_18:
	testl	%r12d, %r12d
	je	LBB0_20
## %bb.19:
	leaq	L_.str.1(%rip), %rdi
	movl	%r12d, %esi
	xorl	%eax, %eax
	callq	_dbg
LBB0_20:
	movq	_R852_CARD_STA_CD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	testl	%eax, %r13d
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	je	LBB0_22
## %bb.21:
	leaq	L_.str.2(%rip), %rdi
	movl	%r13d, %esi
	xorl	%eax, %eax
	callq	_dbg
	jmp	LBB0_22
LBB0_6:
	xorl	%edi, %edi
	cmpl	$0, 8(%r14)
	sete	%dil
	callq	_WARN_ON_ONCE
	movl	8(%r14), %eax
	testl	%eax, %eax
	je	LBB0_22
## %bb.7:
	movq	16(%r14), %rdx
	movq	_DMA_INTERNAL@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	%rcx, %rdx
	jne	LBB0_10
## %bb.8:
	movq	_R852_DMA_IRQ_INTERNAL@GOTPCREL(%rip), %rsi
	testl	%r12d, (%rsi)
	je	LBB0_10
## %bb.9:
	movq	_DMA_MEMORY@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	%rdx, 16(%r14)
	incl	%eax
	movl	%eax, 8(%r14)
LBB0_10:
	movq	_DMA_MEMORY@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rdx
	jne	LBB0_13
## %bb.11:
	movq	_R852_DMA_IRQ_MEMORY@GOTPCREL(%rip), %rdx
	testl	%r12d, (%rdx)
	je	LBB0_13
## %bb.12:
	movq	%rcx, 16(%r14)
	incl	%eax
	movl	%eax, 8(%r14)
LBB0_13:
	cmpl	$2, %eax
	jne	LBB0_15
## %bb.14:
	movq	%r14, %rdi
	callq	_r852_dma_enable
	movl	8(%r14), %eax
LBB0_15:
	cmpl	$3, %eax
	jne	LBB0_22
## %bb.16:
	movq	%r14, %rdi
	xorl	%esi, %esi
	jmp	LBB0_17
LBB0_22:
	movq	%r15, %rdi
	callq	_spin_unlock_irqrestore
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IRQ_NONE,4,2                   ## @IRQ_NONE
	.comm	_R852_CARD_IRQ_STA,4,2          ## @R852_CARD_IRQ_STA
	.comm	_R852_CARD_IRQ_INSERT,4,2       ## @R852_CARD_IRQ_INSERT
	.comm	_R852_CARD_IRQ_REMOVE,4,2       ## @R852_CARD_IRQ_REMOVE
	.comm	_IRQ_HANDLED,4,2                ## @IRQ_HANDLED
	.comm	_R852_DMA_IRQ_STA,4,2           ## @R852_DMA_IRQ_STA
	.comm	_R852_DMA_IRQ_MASK,4,2          ## @R852_DMA_IRQ_MASK
	.comm	_R852_DMA_IRQ_ERROR,4,2         ## @R852_DMA_IRQ_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"received dma error IRQ"

	.comm	_EIO,4,2                        ## @EIO
	.comm	_DMA_INTERNAL,8,3               ## @DMA_INTERNAL
	.comm	_R852_DMA_IRQ_INTERNAL,4,2      ## @R852_DMA_IRQ_INTERNAL
	.comm	_DMA_MEMORY,8,3                 ## @DMA_MEMORY
	.comm	_R852_DMA_IRQ_MEMORY,4,2        ## @R852_DMA_IRQ_MEMORY
L_.str.1:                               ## @.str.1
	.asciz	"bad dma IRQ status = %x"

	.comm	_R852_CARD_STA_CD,4,2           ## @R852_CARD_STA_CD
L_.str.2:                               ## @.str.2
	.asciz	"strange card status = %x"

	.no_dead_strip	_r852_irq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function r852_irq
_r852_irq:                              ; @r852_irq
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x21, x1
Lloh0:
	adrp	x8, _IRQ_NONE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IRQ_NONE@GOTPAGEOFF]
Lloh2:
	ldr	w20, [x8]
	add	x19, x1, #24
	mov	x0, x19
	bl	_spin_lock_irqsave
Lloh3:
	adrp	x22, _R852_CARD_IRQ_STA@GOTPAGE
Lloh4:
	ldr	x22, [x22, _R852_CARD_IRQ_STA@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x21
	bl	_r852_read_reg
	mov	x23, x0
	ldr	w1, [x22]
	mov	x0, x21
	mov	x2, x23
	bl	_r852_write_reg
Lloh5:
	adrp	x8, _R852_CARD_IRQ_INSERT@GOTPAGE
Lloh6:
	ldr	x8, [x8, _R852_CARD_IRQ_INSERT@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
Lloh8:
	adrp	x9, _R852_CARD_IRQ_REMOVE@GOTPAGE
Lloh9:
	ldr	x9, [x9, _R852_CARD_IRQ_REMOVE@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	orr	w9, w9, w8
	tst	w9, w23
	b.eq	LBB0_3
; %bb.1:
Lloh11:
	adrp	x9, _IRQ_HANDLED@GOTPAGE
Lloh12:
	ldr	x9, [x9, _IRQ_HANDLED@GOTPAGEOFF]
Lloh13:
	ldr	w20, [x9]
	tst	w8, w23
	cset	w8, ne
	str	w8, [x21]
	ldr	w0, [x21, #4]
	bl	_WARN_ON
	mov	x0, x21
	bl	_r852_disable_irqs
	ldr	w8, [x21, #4]
	cbnz	w8, LBB0_22
; %bb.2:
	mov	w8, #1
	str	w8, [x21, #4]
	ldr	w22, [x21, #36]
	add	x21, x21, #32
	mov	w0, #100
	bl	_msecs_to_jiffies
	mov	x2, x0
	mov	x0, x22
	mov	x1, x21
	bl	_queue_delayed_work
	b	LBB0_22
LBB0_3:
Lloh14:
	adrp	x24, _R852_DMA_IRQ_STA@GOTPAGE
Lloh15:
	ldr	x24, [x24, _R852_DMA_IRQ_STA@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	x0, x21
	bl	_r852_read_reg_dword
	mov	x22, x0
	ldr	w1, [x24]
	mov	x0, x21
	mov	x2, x22
	bl	_r852_write_reg_dword
Lloh16:
	adrp	x8, _R852_DMA_IRQ_MASK@GOTPAGE
Lloh17:
	ldr	x8, [x8, _R852_DMA_IRQ_MASK@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_7
; %bb.4:
Lloh19:
	adrp	x8, _IRQ_HANDLED@GOTPAGE
Lloh20:
	ldr	x8, [x8, _IRQ_HANDLED@GOTPAGEOFF]
Lloh21:
	ldr	w20, [x8]
Lloh22:
	adrp	x8, _R852_DMA_IRQ_ERROR@GOTPAGE
Lloh23:
	ldr	x8, [x8, _R852_DMA_IRQ_ERROR@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_11
; %bb.5:
Lloh25:
	adrp	x0, l_.str@PAGE
Lloh26:
	add	x0, x0, l_.str@PAGEOFF
	bl	_dbg
Lloh27:
	adrp	x8, _EIO@GOTPAGE
Lloh28:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	neg	w1, w8
	mov	x0, x21
LBB0_6:
	bl	_r852_dma_done
	add	x0, x21, #28
	bl	_complete
	b	LBB0_22
LBB0_7:
	cbz	w22, LBB0_9
; %bb.8:
	str	x22, [sp]
Lloh30:
	adrp	x0, l_.str.1@PAGE
Lloh31:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_dbg
LBB0_9:
Lloh32:
	adrp	x8, _R852_CARD_STA_CD@GOTPAGE
Lloh33:
	ldr	x8, [x8, _R852_CARD_STA_CD@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
	bics	wzr, w23, w8
	b.eq	LBB0_22
; %bb.10:
	str	x23, [sp]
Lloh35:
	adrp	x0, l_.str.2@PAGE
Lloh36:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_dbg
	b	LBB0_22
LBB0_11:
	ldr	w8, [x21, #8]
	cmp	w8, #0
	cset	w0, eq
	bl	_WARN_ON_ONCE
	ldr	w8, [x21, #8]
	cbz	w8, LBB0_22
; %bb.12:
	ldr	x10, [x21, #16]
Lloh37:
	adrp	x9, _DMA_INTERNAL@GOTPAGE
Lloh38:
	ldr	x9, [x9, _DMA_INTERNAL@GOTPAGEOFF]
Lloh39:
	ldr	x9, [x9]
Lloh40:
	adrp	x11, _DMA_MEMORY@GOTPAGE
Lloh41:
	ldr	x11, [x11, _DMA_MEMORY@GOTPAGEOFF]
	cmp	x10, x9
	b.ne	LBB0_15
; %bb.13:
Lloh42:
	adrp	x12, _R852_DMA_IRQ_INTERNAL@GOTPAGE
Lloh43:
	ldr	x12, [x12, _R852_DMA_IRQ_INTERNAL@GOTPAGEOFF]
Lloh44:
	ldr	w12, [x12]
	tst	w12, w22
	b.eq	LBB0_15
; %bb.14:
	ldr	x10, [x11]
	str	x10, [x21, #16]
	add	w8, w8, #1
	str	w8, [x21, #8]
LBB0_15:
	ldr	x11, [x11]
	cmp	x10, x11
	b.ne	LBB0_18
; %bb.16:
Lloh45:
	adrp	x10, _R852_DMA_IRQ_MEMORY@GOTPAGE
Lloh46:
	ldr	x10, [x10, _R852_DMA_IRQ_MEMORY@GOTPAGEOFF]
Lloh47:
	ldr	w10, [x10]
	tst	w10, w22
	b.eq	LBB0_18
; %bb.17:
	str	x9, [x21, #16]
	add	w8, w8, #1
	str	w8, [x21, #8]
LBB0_18:
	cmp	w8, #2
	b.ne	LBB0_20
; %bb.19:
	mov	x0, x21
	bl	_r852_dma_enable
	ldr	w8, [x21, #8]
LBB0_20:
	cmp	w8, #3
	b.ne	LBB0_22
; %bb.21:
	mov	x0, x21
	mov	w1, #0
	b	LBB0_6
LBB0_22:
	mov	x0, x19
	bl	_spin_unlock_irqrestore
	mov	x0, x20
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.cfi_endproc
                                        ; -- End function
	.comm	_IRQ_NONE,4,2                   ; @IRQ_NONE
	.comm	_R852_CARD_IRQ_STA,4,2          ; @R852_CARD_IRQ_STA
	.comm	_R852_CARD_IRQ_INSERT,4,2       ; @R852_CARD_IRQ_INSERT
	.comm	_R852_CARD_IRQ_REMOVE,4,2       ; @R852_CARD_IRQ_REMOVE
	.comm	_IRQ_HANDLED,4,2                ; @IRQ_HANDLED
	.comm	_R852_DMA_IRQ_STA,4,2           ; @R852_DMA_IRQ_STA
	.comm	_R852_DMA_IRQ_MASK,4,2          ; @R852_DMA_IRQ_MASK
	.comm	_R852_DMA_IRQ_ERROR,4,2         ; @R852_DMA_IRQ_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"received dma error IRQ"

	.comm	_EIO,4,2                        ; @EIO
	.comm	_DMA_INTERNAL,8,3               ; @DMA_INTERNAL
	.comm	_R852_DMA_IRQ_INTERNAL,4,2      ; @R852_DMA_IRQ_INTERNAL
	.comm	_DMA_MEMORY,8,3                 ; @DMA_MEMORY
	.comm	_R852_DMA_IRQ_MEMORY,4,2        ; @R852_DMA_IRQ_MEMORY
l_.str.1:                               ; @.str.1
	.asciz	"bad dma IRQ status = %x"

	.comm	_R852_CARD_STA_CD,4,2           ; @R852_CARD_STA_CD
l_.str.2:                               ; @.str.2
	.asciz	"strange card status = %x"

	.no_dead_strip	_r852_irq
.subsections_via_symbols
