	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pxa3xx_nand_irq
_pxa3xx_nand_irq:                       ## @pxa3xx_nand_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	_NDSR@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%rbx, %rdi
	callq	_nand_readl
	movl	%eax, %r14d
	movq	_NDSR_RDDREQ@GOTPCREL(%rip), %rcx
	movq	_NDSR_DBERR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	(%rcx), %esi
	orl	%eax, %esi
	movq	_NDSR_SBERR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	%ecx, %esi
	testl	%r14d, %esi
	je	LBB0_9
## %bb.1:
	testl	%r14d, %eax
	je	LBB0_3
## %bb.2:
	movq	_ERR_DBERR@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_9:
	movq	_NDSR_WRDREQ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	testl	%r14d, %esi
	je	LBB0_13
## %bb.10:
	movq	%rbx, %rdi
	callq	_disable_int
	cmpq	$0, 16(%rbx)
	je	LBB0_12
## %bb.11:
	movq	_STATE_DMA_WRITING@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%rbx)
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_start_data_dma
	jmp	LBB0_18
LBB0_3:
	testl	%r14d, %ecx
	je	LBB0_6
## %bb.4:
	movq	_ERR_SBERR@GOTPCREL(%rip), %rax
LBB0_5:
	movl	(%rax), %eax
	movl	%eax, 8(%rbx)
LBB0_6:
	movq	%rbx, %rdi
	callq	_disable_int
	cmpq	$0, 16(%rbx)
	je	LBB0_8
## %bb.7:
	movq	_STATE_DMA_READING@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%rbx)
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_start_data_dma
	jmp	LBB0_18
LBB0_8:
	movq	_STATE_PIO_READING@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_13:
	movq	_NDSR_CS0_BBD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_NDSR_CS0_CMDD@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	%eax, %esi
	testl	%r14d, %esi
	je	LBB0_18
## %bb.14:
	testl	%r14d, %eax
	je	LBB0_16
## %bb.15:
	movq	_ERR_BBERR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%rbx)
LBB0_16:
	movq	%rbx, %rdi
	callq	_disable_int
	movq	_STATE_READY@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_12:
	movq	_STATE_PIO_WRITING@GOTPCREL(%rip), %rax
LBB0_17:
	movl	(%rax), %eax
	movl	%eax, 4(%rbx)
	movq	%rbx, %rdi
	callq	_complete
LBB0_18:
	movl	(%r15), %esi
	movq	%rbx, %rdi
	movl	%r14d, %edx
	callq	_nand_writel
	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	_NDSR,4,2                       ## @NDSR
	.comm	_NDSR_RDDREQ,4,2                ## @NDSR_RDDREQ
	.comm	_NDSR_DBERR,4,2                 ## @NDSR_DBERR
	.comm	_NDSR_SBERR,4,2                 ## @NDSR_SBERR
	.comm	_ERR_DBERR,4,2                  ## @ERR_DBERR
	.comm	_ERR_SBERR,4,2                  ## @ERR_SBERR
	.comm	_STATE_DMA_READING,4,2          ## @STATE_DMA_READING
	.comm	_STATE_PIO_READING,4,2          ## @STATE_PIO_READING
	.comm	_NDSR_WRDREQ,4,2                ## @NDSR_WRDREQ
	.comm	_STATE_DMA_WRITING,4,2          ## @STATE_DMA_WRITING
	.comm	_STATE_PIO_WRITING,4,2          ## @STATE_PIO_WRITING
	.comm	_NDSR_CS0_BBD,4,2               ## @NDSR_CS0_BBD
	.comm	_NDSR_CS0_CMDD,4,2              ## @NDSR_CS0_CMDD
	.comm	_ERR_BBERR,4,2                  ## @ERR_BBERR
	.comm	_STATE_READY,4,2                ## @STATE_READY
	.comm	_IRQ_HANDLED,4,2                ## @IRQ_HANDLED
	.no_dead_strip	_pxa3xx_nand_irq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pxa3xx_nand_irq
_pxa3xx_nand_irq:                       ; @pxa3xx_nand_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
Lloh0:
	adrp	x21, _NDSR@GOTPAGE
Lloh1:
	ldr	x21, [x21, _NDSR@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	bl	_nand_readl
	mov	x20, x0
Lloh2:
	adrp	x8, _NDSR_RDDREQ@GOTPAGE
Lloh3:
	ldr	x8, [x8, _NDSR_RDDREQ@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x8]
Lloh5:
	adrp	x8, _NDSR_DBERR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _NDSR_DBERR@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	orr	w10, w8, w9
Lloh8:
	adrp	x9, _NDSR_SBERR@GOTPAGE
Lloh9:
	ldr	x9, [x9, _NDSR_SBERR@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	orr	w1, w10, w9
	tst	w1, w0
	b.eq	LBB0_3
; %bb.1:
	tst	w8, w20
	b.eq	LBB0_6
; %bb.2:
Lloh11:
	adrp	x8, _ERR_DBERR@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ERR_DBERR@GOTPAGEOFF]
	b	LBB0_8
LBB0_3:
Lloh13:
	adrp	x8, _NDSR_WRDREQ@GOTPAGE
Lloh14:
	ldr	x8, [x8, _NDSR_WRDREQ@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	tst	w1, w20
	b.eq	LBB0_12
; %bb.4:
	mov	x0, x19
	bl	_disable_int
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_16
; %bb.5:
Lloh16:
	adrp	x8, _STATE_DMA_WRITING@GOTPAGE
Lloh17:
	ldr	x8, [x8, _STATE_DMA_WRITING@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	str	w8, [x19, #4]
	mov	x0, x19
	mov	w1, #1
	bl	_start_data_dma
	b	LBB0_18
LBB0_6:
	tst	w9, w20
	b.eq	LBB0_9
; %bb.7:
Lloh19:
	adrp	x8, _ERR_SBERR@GOTPAGE
Lloh20:
	ldr	x8, [x8, _ERR_SBERR@GOTPAGEOFF]
LBB0_8:
	ldr	w8, [x8]
	str	w8, [x19, #8]
LBB0_9:
	mov	x0, x19
	bl	_disable_int
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_11
; %bb.10:
Lloh21:
	adrp	x8, _STATE_DMA_READING@GOTPAGE
Lloh22:
	ldr	x8, [x8, _STATE_DMA_READING@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	str	w8, [x19, #4]
	mov	x0, x19
	mov	w1, #0
	bl	_start_data_dma
	b	LBB0_18
LBB0_11:
Lloh24:
	adrp	x8, _STATE_PIO_READING@GOTPAGE
Lloh25:
	ldr	x8, [x8, _STATE_PIO_READING@GOTPAGEOFF]
	b	LBB0_17
LBB0_12:
Lloh26:
	adrp	x8, _NDSR_CS0_BBD@GOTPAGE
Lloh27:
	ldr	x8, [x8, _NDSR_CS0_BBD@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
Lloh29:
	adrp	x9, _NDSR_CS0_CMDD@GOTPAGE
Lloh30:
	ldr	x9, [x9, _NDSR_CS0_CMDD@GOTPAGEOFF]
Lloh31:
	ldr	w9, [x9]
	orr	w1, w9, w8
	tst	w1, w20
	b.eq	LBB0_18
; %bb.13:
	tst	w8, w20
	b.eq	LBB0_15
; %bb.14:
Lloh32:
	adrp	x8, _ERR_BBERR@GOTPAGE
Lloh33:
	ldr	x8, [x8, _ERR_BBERR@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
	str	w8, [x19, #8]
LBB0_15:
	mov	x0, x19
	bl	_disable_int
Lloh35:
	adrp	x8, _STATE_READY@GOTPAGE
Lloh36:
	ldr	x8, [x8, _STATE_READY@GOTPAGEOFF]
	b	LBB0_17
LBB0_16:
Lloh37:
	adrp	x8, _STATE_PIO_WRITING@GOTPAGE
Lloh38:
	ldr	x8, [x8, _STATE_PIO_WRITING@GOTPAGEOFF]
LBB0_17:
	ldr	w8, [x8]
	str	w8, [x19, #4]
	mov	x0, x19
	bl	_complete
LBB0_18:
	ldr	w1, [x21]
	mov	x0, x19
	mov	x2, x20
	bl	_nand_writel
Lloh39:
	adrp	x8, _IRQ_HANDLED@GOTPAGE
Lloh40:
	ldr	x8, [x8, _IRQ_HANDLED@GOTPAGEOFF]
Lloh41:
	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	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.cfi_endproc
                                        ; -- End function
	.comm	_NDSR,4,2                       ; @NDSR
	.comm	_NDSR_RDDREQ,4,2                ; @NDSR_RDDREQ
	.comm	_NDSR_DBERR,4,2                 ; @NDSR_DBERR
	.comm	_NDSR_SBERR,4,2                 ; @NDSR_SBERR
	.comm	_ERR_DBERR,4,2                  ; @ERR_DBERR
	.comm	_ERR_SBERR,4,2                  ; @ERR_SBERR
	.comm	_STATE_DMA_READING,4,2          ; @STATE_DMA_READING
	.comm	_STATE_PIO_READING,4,2          ; @STATE_PIO_READING
	.comm	_NDSR_WRDREQ,4,2                ; @NDSR_WRDREQ
	.comm	_STATE_DMA_WRITING,4,2          ; @STATE_DMA_WRITING
	.comm	_STATE_PIO_WRITING,4,2          ; @STATE_PIO_WRITING
	.comm	_NDSR_CS0_BBD,4,2               ; @NDSR_CS0_BBD
	.comm	_NDSR_CS0_CMDD,4,2              ; @NDSR_CS0_CMDD
	.comm	_ERR_BBERR,4,2                  ; @ERR_BBERR
	.comm	_STATE_READY,4,2                ; @STATE_READY
	.comm	_IRQ_HANDLED,4,2                ; @IRQ_HANDLED
	.no_dead_strip	_pxa3xx_nand_irq
.subsections_via_symbols
