	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lpc32xx_nand_write_page_syndrome
_lpc32xx_nand_write_page_syndrome:      ## @lpc32xx_nand_write_page_syndrome
	.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
	movl	%ecx, %r12d
	movq	%rsi, %r13
	movq	%rdi, %rbx
	callq	_nand_to_mtd
	movq	%rax, %r14
	movq	%rbx, %rdi
	callq	_nand_get_controller_data
	movq	%rax, %r15
	movl	$0, -48(%rbp)
	movq	%rbx, %rdi
	movl	%r12d, %esi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_nand_prog_page_begin_op
	movl	16(%rbx), %edx
	movq	%r14, %rdi
	movq	%r13, %rsi
	xorl	%ecx, %ecx
	callq	_lpc32xx_xfer
	testl	%eax, %eax
	jne	LBB0_3
## %bb.1:
	leaq	-48(%rbp), %rdx
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_mtd_ooblayout_ecc
	testl	%eax, %eax
	jne	LBB0_3
## %bb.2:
	movslq	-48(%rbp), %rdi
	shlq	$2, %rdi
	addq	(%rbx), %rdi
	movq	(%r15), %rsi
	movl	16(%rbx), %edx
	callq	_lpc32xx_slc_ecc_copy
	movq	(%rbx), %rsi
	movl	(%r14), %edx
	movq	%rbx, %rdi
	callq	*8(%rbx)
	movq	%rbx, %rdi
	callq	_nand_prog_page_end_op
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_lpc32xx_nand_write_page_syndrome
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lpc32xx_nand_write_page_syndrome
_lpc32xx_nand_write_page_syndrome:      ; @lpc32xx_nand_write_page_syndrome
	.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	x22, x3
	mov	x23, x1
	mov	x19, x0
	bl	_nand_to_mtd
	mov	x20, x0
	mov	x0, x19
	bl	_nand_get_controller_data
	mov	x21, x0
	str	wzr, [sp, #8]
	mov	x0, x19
	mov	x1, x22
	mov	w2, #0
	mov	x3, #0
	mov	w4, #0
	bl	_nand_prog_page_begin_op
	ldr	w2, [x19, #16]
	mov	x0, x20
	mov	x1, x23
	mov	w3, #0
	bl	_lpc32xx_xfer
	cbnz	w0, LBB0_3
; %bb.1:
	add	x2, sp, #8
	mov	x0, x20
	mov	w1, #0
	bl	_mtd_ooblayout_ecc
	cbnz	w0, LBB0_3
; %bb.2:
	ldr	x8, [x19]
	ldrsw	x9, [sp, #8]
	add	x0, x8, x9, lsl #2
	ldr	x1, [x21]
	ldr	w2, [x19, #16]
	bl	_lpc32xx_slc_ecc_copy
	ldp	x1, x8, [x19]
	ldr	w2, [x20]
	mov	x0, x19
	blr	x8
	mov	x0, x19
	bl	_nand_prog_page_end_op
LBB0_3:
	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
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_lpc32xx_nand_write_page_syndrome
.subsections_via_symbols
