	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sunxi_nfc_hw_ecc_read_subpage_dma
_sunxi_nfc_hw_ecc_read_subpage_dma:     ## @sunxi_nfc_hw_ecc_read_subpage_dma
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, %r13d
	movq	%rcx, %r15
	movq	%rsi, %r12
	movq	%rdi, %rbx
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	leaq	(%rdx,%rsi), %rdi
	movl	4(%rbx), %esi
	callq	_DIV_ROUND_UP
	movl	%eax, %r14d
	movl	(%rbx), %esi
	movq	%rbx, %rdi
	callq	_sunxi_nfc_select_chip
	movq	%rbx, %rdi
	movl	%r13d, %esi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_nand_read_page_op
	movq	%rbx, %rdi
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	movq	%r15, %rsi
	xorl	%edx, %edx
	movl	%r13d, %ecx
	movl	%r14d, %r8d
	callq	_sunxi_nfc_hw_ecc_read_chunks_dma
	testl	%eax, %eax
	js	LBB0_2
## %bb.1:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movq	%rbx, %rdi
	movq	%r12, %rsi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movl	%r13d, %r8d
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_sunxi_nfc_hw_ecc_read_subpage  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_sunxi_nfc_hw_ecc_read_subpage_dma
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sunxi_nfc_hw_ecc_read_subpage_dma
_sunxi_nfc_hw_ecc_read_subpage_dma:     ; @sunxi_nfc_hw_ecc_read_subpage_dma
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x19, x4
	mov	x20, x3
	mov	x21, x2
	mov	x22, x1
	mov	x23, x0
	add	x0, x2, x1
	ldr	w1, [x23, #4]
	bl	_DIV_ROUND_UP
	mov	x24, x0
	ldr	w1, [x23]
	mov	x0, x23
	bl	_sunxi_nfc_select_chip
	mov	x0, x23
	mov	x1, x19
	mov	w2, #0
	mov	x3, #0
	mov	w4, #0
	bl	_nand_read_page_op
	mov	x0, x23
	mov	x1, x20
	mov	w2, #0
	mov	x3, x19
	mov	x4, x24
	bl	_sunxi_nfc_hw_ecc_read_chunks_dma
	tbnz	w0, #31, LBB0_2
; %bb.1:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_2:
	mov	x0, x23
	mov	x1, x22
	mov	x2, x21
	mov	x3, x20
	mov	x4, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_sunxi_nfc_hw_ecc_read_subpage
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_sunxi_nfc_hw_ecc_read_subpage_dma
.subsections_via_symbols
