	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function atmel_smc_nand_setup_data_interface
_atmel_smc_nand_setup_data_interface:   ## @atmel_smc_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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movl	8(%rdi), %edi
	callq	_to_nand_controller
	movq	%rax, %r12
	leaq	-40(%rbp), %rdx
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_atmel_smc_nand_prepare_smcconf
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_3
## %bb.1:
	movq	_NAND_DATA_IFACE_CHECK_ONLY@GOTPCREL(%rip), %rax
	cmpl	%r14d, (%rax)
	je	LBB0_3
## %bb.2:
	movq	(%rbx), %rax
	movslq	%r14d, %rcx
	leaq	(%rax,%rcx,8), %rdx
	movl	-40(%rbp), %esi
	movl	%esi, (%rax,%rcx,8)
	movl	(%r12), %edi
	movl	4(%rax,%rcx,8), %esi
	callq	_atmel_smc_cs_conf_apply
LBB0_3:
	movl	%r15d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NAND_DATA_IFACE_CHECK_ONLY,4,2 ## @NAND_DATA_IFACE_CHECK_ONLY
	.no_dead_strip	_atmel_smc_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 atmel_smc_nand_setup_data_interface
_atmel_smc_nand_setup_data_interface:   ; @atmel_smc_nand_setup_data_interface
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	ldr	w0, [x0, #8]
	bl	_to_nand_controller
	mov	x22, x0
	add	x2, sp, #8
	mov	x0, x20
	mov	x1, x21
	bl	_atmel_smc_nand_prepare_smcconf
	mov	x21, x0
	cbnz	w0, LBB0_3
; %bb.1:
Lloh0:
	adrp	x8, _NAND_DATA_IFACE_CHECK_ONLY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NAND_DATA_IFACE_CHECK_ONLY@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w19
	b.eq	LBB0_3
; %bb.2:
	ldr	x8, [x20]
	add	x2, x8, w19, sxtw #3
	ldr	w8, [sp, #8]
	str	w8, [x2]
	ldr	w0, [x22]
	ldr	w1, [x2, #4]
	bl	_atmel_smc_cs_conf_apply
LBB0_3:
	mov	x0, x21
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_NAND_DATA_IFACE_CHECK_ONLY,4,2 ; @NAND_DATA_IFACE_CHECK_ONLY
	.no_dead_strip	_atmel_smc_nand_setup_data_interface
.subsections_via_symbols
