	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nand_fill_column_cycles
_nand_fill_column_cycles:               ## @nand_fill_column_cycles
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %ebx
	movq	%rsi, %r14
	movq	%rdi, %r12
	callq	_nand_to_mtd
	movq	%rax, %r15
	movl	(%rax), %eax
	movl	4(%r15), %ecx
	addl	%eax, %ecx
	cmpl	%ebx, %ecx
	jb	LBB0_1
## %bb.2:
	xorl	%ecx, %ecx
	cmpl	%ebx, %eax
	movl	%eax, %edx
	cmoval	%ecx, %edx
	cmpl	$513, %eax                      ## imm = 0x201
	cmovael	%ecx, %edx
	subl	%edx, %ebx
	movq	_NAND_BUSWIDTH_16@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r12)
	je	LBB0_5
## %bb.3:
	movl	%ebx, %edi
	andl	$1, %edi
	callq	_WARN_ON
	testq	%rax, %rax
	je	LBB0_4
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_7:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	shrl	%ebx
LBB0_5:
	movl	%ebx, (%r14)
	movl	$1, %eax
	cmpl	$513, (%r15)                    ## imm = 0x201
	jb	LBB0_7
## %bb.6:
	shrl	$8, %ebx
	movl	%ebx, 4(%r14)
	movl	$2, %eax
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_NAND_BUSWIDTH_16,4,2           ## @NAND_BUSWIDTH_16
	.no_dead_strip	_nand_fill_column_cycles
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nand_fill_column_cycles
_nand_fill_column_cycles:               ; @nand_fill_column_cycles
	.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	x21, x2
	mov	x19, x1
	mov	x22, x0
	bl	_nand_to_mtd
	ldp	w8, w9, [x0]
	add	w9, w9, w8
	cmp	w9, w21
	b.lo	LBB0_3
; %bb.1:
	mov	x20, x0
	cmp	w8, w21
	mov	w9, #512
	ccmp	w8, w9, #2, ls
	csel	w8, wzr, w8, hi
	sub	w21, w21, w8
	ldr	w8, [x22]
Lloh0:
	adrp	x9, _NAND_BUSWIDTH_16@GOTPAGE
Lloh1:
	ldr	x9, [x9, _NAND_BUSWIDTH_16@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_6
; %bb.2:
	and	w0, w21, #0x1
	bl	_WARN_ON
	cbz	x0, LBB0_5
LBB0_3:
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	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
LBB0_5:
	lsr	w21, w21, #1
LBB0_6:
	str	w21, [x19]
	ldr	w8, [x20]
	cmp	w8, #513
	b.hs	LBB0_8
; %bb.7:
	mov	w0, #1
	b	LBB0_4
LBB0_8:
	lsr	w8, w21, #8
	str	w8, [x19, #4]
	mov	w0, #2
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_NAND_BUSWIDTH_16,4,2           ; @NAND_BUSWIDTH_16
	.no_dead_strip	_nand_fill_column_cycles
.subsections_via_symbols
