	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function s3c2410_nand_setup_data_interface
_s3c2410_nand_setup_data_interface:     ## @s3c2410_nand_setup_data_interface
	.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	%rdx, %rbx
	callq	_nand_to_mtd
	movq	%rax, %rdi
	callq	_s3c2410_nand_mtd_toinfo
	movq	%rax, %r14
	movq	(%rax), %r15
	movq	%rbx, %rdi
	callq	_nand_get_sdr_timings
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_ENOTSUPP@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movl	(%rbx), %eax
	subl	4(%rbx), %eax
	xorl	%edi, %edi
	testl	%eax, %eax
	cmovgl	%eax, %edi
	movl	$1000, %esi                     ## imm = 0x3E8
	callq	_DIV_ROUND_UP
	movq	%rax, 16(%r15)
	movl	4(%rbx), %edi
	movl	$1000, %esi                     ## imm = 0x3E8
	callq	_DIV_ROUND_UP
	movq	%rax, 8(%r15)
	movl	8(%rbx), %edi
	movl	$1000, %esi                     ## imm = 0x3E8
	callq	_DIV_ROUND_UP
	movq	%rax, (%r15)
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_s3c2410_nand_setrate           ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOTSUPP,4,2                   ## @ENOTSUPP
	.no_dead_strip	_s3c2410_nand_setup_data_interface
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function s3c2410_nand_setup_data_interface
_s3c2410_nand_setup_data_interface:     ; @s3c2410_nand_setup_data_interface
	.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	x20, x2
	bl	_nand_to_mtd
	bl	_s3c2410_nand_mtd_toinfo
	mov	x19, x0
	ldr	x21, [x0]
	mov	x0, x20
	bl	_nand_get_sdr_timings
	mov	x20, x0
	bl	_IS_ERR
	cbz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _ENOTSUPP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOTSUPP@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	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_2:
	ldp	w8, w9, [x20]
	sub	w8, w8, w9
	cmp	w8, #0
	csel	w0, w8, wzr, gt
	mov	w1, #1000
	bl	_DIV_ROUND_UP
	str	x0, [x21, #16]
	ldr	w0, [x20, #4]
	mov	w1, #1000
	bl	_DIV_ROUND_UP
	str	x0, [x21, #8]
	ldr	w0, [x20, #8]
	mov	w1, #1000
	bl	_DIV_ROUND_UP
	str	x0, [x21]
	mov	x0, x19
	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
	b	_s3c2410_nand_setrate
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOTSUPP,4,2                   ; @ENOTSUPP
	.no_dead_strip	_s3c2410_nand_setup_data_interface
.subsections_via_symbols
