	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function omap_nand_attach_chip
_omap_nand_attach_chip:                 ## @omap_nand_attach_chip
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r12
	callq	_nand_to_mtd
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_mtd_to_omap
	movq	%rax, %r13
	movq	24(%rax), %r14
	movq	_BADBLOCK_MARKER_LENGTH@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	(%r12), %eax
	movq	_NAND_BBT_USE_FLASH@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_2
## %bb.1:
	movq	_NAND_BBT_NO_OOB@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, (%r12)
	jmp	LBB0_3
LBB0_2:
	movq	_NAND_SKIP_BBTSCAN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 4(%r12)
LBB0_3:
	movl	(%r13), %edx
	leal	-134(%rdx), %eax
	cmpl	$3, %eax
	ja	LBB0_9
## %bb.4:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_5:
	movq	_omap_read_buf_pref@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 100(%r12)
	movq	_omap_write_buf_pref@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 96(%r12)
LBB0_6:
	movq	%r13, %rdi
	callq	_omap2_nand_ecc_check
	testl	%eax, %eax
	je	LBB0_16
## %bb.7:
	movl	12(%r13), %eax
	movq	_OMAP_ECC_HAM1_CODE_SW@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_17
## %bb.8:
	movq	_NAND_ECC_SOFT@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 64(%r12)
	movq	_NAND_ECC_HAMMING@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 88(%r12)
	xorl	%ebx, %ebx
	jmp	LBB0_23
LBB0_9:
	leaq	L_.str.8(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r14, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	xorl	%eax, %eax
	callq	_dev_err
LBB0_10:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_22
LBB0_11:
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_platform_get_irq
	movl	%eax, 4(%r13)
	testl	%eax, %eax
	jle	LBB0_20
## %bb.12:
	movq	_omap_nand_irq@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	_IRQF_SHARED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	leaq	L_.str.4(%rip), %r8
	movq	%r14, %rdi
	movl	%eax, %esi
	movq	%r13, %r9
	callq	_devm_request_irq
	testl	%eax, %eax
	je	LBB0_26
## %bb.13:
	movl	%eax, %ebx
	movl	4(%r13), %edx
	leaq	L_.str.5(%rip), %rsi
	movq	%r14, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	movl	$0, 4(%r13)
	jmp	LBB0_23
LBB0_14:
	callq	_dma_cap_zero
	movq	_DMA_SLAVE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_dma_cap_set
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dma_request_chan
	movl	%eax, 32(%r13)
	movl	%eax, %edi
	callq	_IS_ERR
	testl	%eax, %eax
	je	LBB0_24
## %bb.15:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	movl	32(%r13), %edi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_PTR_ERR                        ## TAILCALL
LBB0_16:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	jmp	LBB0_22
LBB0_17:
	addl	$-128, %eax
	cmpl	$5, %eax
	ja	LBB0_30
## %bb.18:
	leaq	LJTI0_1(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_19:
	leaq	L_.str.9(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_info
	movq	_NAND_ECC_HW@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 64(%r12)
	movabsq	$2199023255555, %rax            ## imm = 0x20000000003
	movq	%rax, 8(%r12)
	movl	$1, 16(%r12)
	movq	_omap_calculate_ecc@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 80(%r12)
	movq	_omap_enable_hwecc@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 56(%r12)
	movq	_omap_correct_data@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 48(%r12)
	movq	_omap_ooblayout_ops@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_mtd_set_ooblayout
	movq	_NAND_BUSWIDTH_16@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 4(%r12)
	movl	8(%r12), %r13d
	movl	$1, %eax
	cmovel	%eax, %ebx
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	jmp	LBB0_40
LBB0_20:
	leaq	L_.str.3(%rip), %rsi
LBB0_21:
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	movq	_ENODEV@GOTPCREL(%rip), %rax
LBB0_22:
	subl	(%rax), %ebx
LBB0_23:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_24:
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	leaq	-80(%rbp), %rbx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movl	36(%r13), %eax
	movl	%eax, -52(%rbp)
	movl	%eax, -56(%rbp)
	movq	_DMA_SLAVE_BUSWIDTH_4_BYTES@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -64(%rbp)
	movq	%rax, -72(%rbp)
	movabsq	$68719476752, %rax              ## imm = 0x1000000010
	movq	%rax, -80(%rbp)
	movl	32(%r13), %edi
	movq	%rbx, %rsi
	callq	_dmaengine_slave_config
	testl	%eax, %eax
	je	LBB0_29
## %bb.25:
	movl	%eax, %ebx
	leaq	L_.str.2(%rip), %rsi
	movq	%r14, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_23
LBB0_26:
	movq	_omap_nand_irq@GOTPCREL(%rip), %rbx
	movq	24(%r13), %rdi
	movl	$1, %esi
	callq	_platform_get_irq
	movl	%eax, 8(%r13)
	testl	%eax, %eax
	jle	LBB0_42
## %bb.27:
	movl	(%rbx), %edx
	movq	_IRQF_SHARED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	leaq	L_.str.7(%rip), %r8
	movq	%r14, %rdi
	movl	%eax, %esi
	movq	%r13, %r9
	callq	_devm_request_irq
	testl	%eax, %eax
	je	LBB0_43
## %bb.28:
	movl	%eax, %ebx
	movl	8(%r13), %edx
	leaq	L_.str.5(%rip), %rsi
	movq	%r14, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	movl	$0, 8(%r13)
	jmp	LBB0_23
LBB0_29:
	movq	_omap_read_buf_dma_pref@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 100(%r12)
	movq	_omap_write_buf_dma_pref@GOTPCREL(%rip), %rax
	jmp	LBB0_44
LBB0_30:
	leaq	L_.str.17(%rip), %rsi
	jmp	LBB0_46
LBB0_31:
	leaq	L_.str.13(%rip), %rdi
	callq	_pr_info
	movq	_NAND_ECC_HW@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 64(%r12)
	movabsq	$2199023255565, %rax            ## imm = 0x2000000000D
	movq	%rax, 8(%r12)
	movl	$8, 16(%r12)
	movq	_omap_enable_hwecc_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 56(%r12)
	movq	_nand_bch_correct_data@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 48(%r12)
	movq	_omap_calculate_ecc_bch_sw@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 80(%r12)
	movq	_omap_sw_ooblayout_ops@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_mtd_set_ooblayout
	movl	8(%r12), %r13d
	movq	%r15, %rdi
	callq	_nand_bch_init
	movq	%rax, 72(%r12)
	testq	%rax, %rax
	jne	LBB0_35
## %bb.32:
	leaq	L_.str.14(%rip), %rsi
	jmp	LBB0_46
LBB0_33:
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	leaq	L_.str.15(%rip), %rdi
	callq	_pr_info
	movq	_NAND_ECC_HW@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 64(%r12)
	movabsq	$2199023255566, %rax            ## imm = 0x2000000000E
	movq	%rax, 8(%r12)
	movl	$8, 16(%r12)
	movq	_omap_enable_hwecc_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 56(%r12)
	movq	_omap_elm_correct_data@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 48(%r12)
	movq	_omap_read_page_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 40(%r12)
	movq	_omap_write_page_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 32(%r12)
	movq	_omap_write_subpage_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 24(%r12)
	movq	_omap_ooblayout_ops@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_mtd_set_ooblayout
	movl	8(%r12), %eax
	movl	12(%r12), %ecx
	movl	16(%r13), %edi
	movl	%eax, %r13d
	movq	_BCH8_ECC@GOTPCREL(%rip), %rax
	jmp	LBB0_37
LBB0_34:
	leaq	L_.str.10(%rip), %rdi
	callq	_pr_info
	movq	_NAND_ECC_HW@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 64(%r12)
	movabsq	$2199023255559, %rax            ## imm = 0x20000000007
	movq	%rax, 8(%r12)
	movl	$4, 16(%r12)
	movq	_omap_enable_hwecc_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 56(%r12)
	movq	_nand_bch_correct_data@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 48(%r12)
	movq	_omap_calculate_ecc_bch_sw@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 80(%r12)
	movq	_omap_sw_ooblayout_ops@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_mtd_set_ooblayout
	movl	8(%r12), %r13d
	movq	%r15, %rdi
	callq	_nand_bch_init
	movq	%rax, 72(%r12)
	testq	%rax, %rax
	je	LBB0_45
LBB0_35:
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	incl	%r13d
	jmp	LBB0_40
LBB0_36:
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	leaq	L_.str.12(%rip), %rdi
	callq	_pr_info
	movq	_NAND_ECC_HW@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 64(%r12)
	movabsq	$2199023255560, %rax            ## imm = 0x20000000008
	movq	%rax, 8(%r12)
	movl	$4, 16(%r12)
	movq	_omap_enable_hwecc_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 56(%r12)
	movq	_omap_elm_correct_data@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 48(%r12)
	movq	_omap_read_page_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 40(%r12)
	movq	_omap_write_page_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 32(%r12)
	movq	_omap_write_subpage_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 24(%r12)
	movq	_omap_ooblayout_ops@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_mtd_set_ooblayout
	movl	8(%r12), %eax
	movl	12(%r12), %ecx
	movl	16(%r13), %edi
	movl	%eax, %r13d
	movq	_BCH4_ECC@GOTPCREL(%rip), %rax
	jmp	LBB0_37
LBB0_39:
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	leaq	L_.str.16(%rip), %rdi
	callq	_pr_info
	movq	_NAND_ECC_HW@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 64(%r12)
	movabsq	$2199023255578, %rax            ## imm = 0x2000000001A
	movq	%rax, 8(%r12)
	movl	$16, 16(%r12)
	movq	_omap_enable_hwecc_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 56(%r12)
	movq	_omap_elm_correct_data@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 48(%r12)
	movq	_omap_read_page_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 40(%r12)
	movq	_omap_write_page_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 32(%r12)
	movq	_omap_write_subpage_bch@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 24(%r12)
	movq	_omap_ooblayout_ops@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_mtd_set_ooblayout
	movl	8(%r12), %eax
	movl	12(%r12), %ecx
	movl	16(%r13), %edi
	movl	%eax, %r13d
	movq	_BCH16_ECC@GOTPCREL(%rip), %rax
LBB0_37:
	movl	(%rax), %esi
	movl	(%r15), %eax
	cltd
	idivl	%ecx
	movl	%eax, %edx
	movl	%r13d, %r8d
	callq	_elm_config
	testl	%eax, %eax
	js	LBB0_38
LBB0_40:
	movl	(%r15), %eax
	movl	4(%r15), %ecx
	cltd
	idivl	12(%r12)
	imull	%r13d, %eax
	addl	-44(%rbp), %eax                 ## 4-byte Folded Reload
	xorl	%ebx, %ebx
	cmpl	%eax, %ecx
	jge	LBB0_23
## %bb.41:
	leaq	L_.str.18(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_10
LBB0_38:
	movl	%eax, %ebx
	jmp	LBB0_23
LBB0_42:
	leaq	L_.str.6(%rip), %rsi
	xorl	%ebx, %ebx
	jmp	LBB0_21
LBB0_43:
	movq	_omap_read_buf_irq_pref@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 100(%r12)
	movq	_omap_write_buf_irq_pref@GOTPCREL(%rip), %rax
LBB0_44:
	movl	(%rax), %eax
	movl	%eax, 96(%r12)
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	jmp	LBB0_6
LBB0_45:
	leaq	L_.str.11(%rip), %rsi
LBB0_46:
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_10
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_11, LBB0_11-LJTI0_0
.set L0_0_set_14, LBB0_14-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
LJTI0_0:
	.long	L0_0_set_5
	.long	L0_0_set_11
	.long	L0_0_set_14
	.long	L0_0_set_6
.set L0_1_set_19, LBB0_19-LJTI0_1
.set L0_1_set_31, LBB0_31-LJTI0_1
.set L0_1_set_33, LBB0_33-LJTI0_1
.set L0_1_set_34, LBB0_34-LJTI0_1
.set L0_1_set_36, LBB0_36-LJTI0_1
.set L0_1_set_39, LBB0_39-LJTI0_1
LJTI0_1:
	.long	L0_1_set_19
	.long	L0_1_set_31
	.long	L0_1_set_33
	.long	L0_1_set_34
	.long	L0_1_set_36
	.long	L0_1_set_39
	.end_data_region
                                        ## -- End function
	.comm	_BADBLOCK_MARKER_LENGTH,4,2     ## @BADBLOCK_MARKER_LENGTH
	.comm	_NAND_BBT_USE_FLASH,4,2         ## @NAND_BBT_USE_FLASH
	.comm	_NAND_BBT_NO_OOB,4,2            ## @NAND_BBT_NO_OOB
	.comm	_NAND_SKIP_BBTSCAN,4,2          ## @NAND_SKIP_BBTSCAN
	.comm	_omap_read_buf_pref,4,2         ## @omap_read_buf_pref
	.comm	_omap_write_buf_pref,4,2        ## @omap_write_buf_pref
	.comm	_DMA_SLAVE,4,2                  ## @DMA_SLAVE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"rxtx"

L_.str.1:                               ## @.str.1
	.asciz	"DMA engine request failed\n"

	.comm	_DMA_SLAVE_BUSWIDTH_4_BYTES,8,3 ## @DMA_SLAVE_BUSWIDTH_4_BYTES
L_.str.2:                               ## @.str.2
	.asciz	"DMA engine slave config failed: %d\n"

	.comm	_omap_read_buf_dma_pref,4,2     ## @omap_read_buf_dma_pref
	.comm	_omap_write_buf_dma_pref,4,2    ## @omap_write_buf_dma_pref
L_.str.3:                               ## @.str.3
	.asciz	"Error getting fifo IRQ\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_omap_nand_irq,4,2              ## @omap_nand_irq
	.comm	_IRQF_SHARED,4,2                ## @IRQF_SHARED
L_.str.4:                               ## @.str.4
	.asciz	"gpmc-nand-fifo"

L_.str.5:                               ## @.str.5
	.asciz	"Requesting IRQ %d, error %d\n"

L_.str.6:                               ## @.str.6
	.asciz	"Error getting IRQ count\n"

L_.str.7:                               ## @.str.7
	.asciz	"gpmc-nand-count"

	.comm	_omap_read_buf_irq_pref,4,2     ## @omap_read_buf_irq_pref
	.comm	_omap_write_buf_irq_pref,4,2    ## @omap_write_buf_irq_pref
L_.str.8:                               ## @.str.8
	.asciz	"xfer_type %d not supported!\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_OMAP_ECC_HAM1_CODE_SW,4,2      ## @OMAP_ECC_HAM1_CODE_SW
	.comm	_NAND_ECC_SOFT,8,3              ## @NAND_ECC_SOFT
	.comm	_NAND_ECC_HAMMING,4,2           ## @NAND_ECC_HAMMING
L_.str.9:                               ## @.str.9
	.asciz	"nand: using OMAP_ECC_HAM1_CODE_HW\n"

	.comm	_NAND_ECC_HW,8,3                ## @NAND_ECC_HW
	.comm	_omap_calculate_ecc,8,3         ## @omap_calculate_ecc
	.comm	_omap_enable_hwecc,8,3          ## @omap_enable_hwecc
	.comm	_omap_correct_data,8,3          ## @omap_correct_data
	.comm	_omap_ooblayout_ops,4,2         ## @omap_ooblayout_ops
	.comm	_NAND_BUSWIDTH_16,4,2           ## @NAND_BUSWIDTH_16
L_.str.10:                              ## @.str.10
	.asciz	"nand: using OMAP_ECC_BCH4_CODE_HW_DETECTION_SW\n"

	.comm	_omap_enable_hwecc_bch,8,3      ## @omap_enable_hwecc_bch
	.comm	_nand_bch_correct_data,8,3      ## @nand_bch_correct_data
	.comm	_omap_calculate_ecc_bch_sw,8,3  ## @omap_calculate_ecc_bch_sw
	.comm	_omap_sw_ooblayout_ops,4,2      ## @omap_sw_ooblayout_ops
L_.str.11:                              ## @.str.11
	.asciz	"Unable to use BCH library\n"

L_.str.12:                              ## @.str.12
	.asciz	"nand: using OMAP_ECC_BCH4_CODE_HW ECC scheme\n"

	.comm	_omap_elm_correct_data,8,3      ## @omap_elm_correct_data
	.comm	_omap_read_page_bch,8,3         ## @omap_read_page_bch
	.comm	_omap_write_page_bch,8,3        ## @omap_write_page_bch
	.comm	_omap_write_subpage_bch,8,3     ## @omap_write_subpage_bch
	.comm	_BCH4_ECC,4,2                   ## @BCH4_ECC
L_.str.13:                              ## @.str.13
	.asciz	"nand: using OMAP_ECC_BCH8_CODE_HW_DETECTION_SW\n"

L_.str.14:                              ## @.str.14
	.asciz	"unable to use BCH library\n"

L_.str.15:                              ## @.str.15
	.asciz	"nand: using OMAP_ECC_BCH8_CODE_HW ECC scheme\n"

	.comm	_BCH8_ECC,4,2                   ## @BCH8_ECC
L_.str.16:                              ## @.str.16
	.asciz	"Using OMAP_ECC_BCH16_CODE_HW ECC scheme\n"

	.comm	_BCH16_ECC,4,2                  ## @BCH16_ECC
L_.str.17:                              ## @.str.17
	.asciz	"Invalid or unsupported ECC scheme\n"

L_.str.18:                              ## @.str.18
	.asciz	"Not enough OOB bytes: required = %d, available=%d\n"

	.no_dead_strip	_omap_nand_attach_chip
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function omap_nand_attach_chip
lCPI0_0:
	.long	26                              ; 0x1a
	.long	512                             ; 0x200
lCPI0_1:
	.long	14                              ; 0xe
	.long	512                             ; 0x200
lCPI0_2:
	.long	13                              ; 0xd
	.long	512                             ; 0x200
lCPI0_3:
	.long	8                               ; 0x8
	.long	512                             ; 0x200
lCPI0_4:
	.long	7                               ; 0x7
	.long	512                             ; 0x200
lCPI0_5:
	.long	3                               ; 0x3
	.long	512                             ; 0x200
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_omap_nand_attach_chip:                 ; @omap_nand_attach_chip
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x0
	bl	_nand_to_mtd
	mov	x21, x0
	bl	_mtd_to_omap
	mov	x22, x0
	ldr	x19, [x0, #24]
Lloh0:
	adrp	x8, _BADBLOCK_MARKER_LENGTH@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BADBLOCK_MARKER_LENGTH@GOTPAGEOFF]
Lloh2:
	ldr	w24, [x8]
	ldr	w8, [x20]
Lloh3:
	adrp	x9, _NAND_BBT_USE_FLASH@GOTPAGE
Lloh4:
	ldr	x9, [x9, _NAND_BBT_USE_FLASH@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.1:
Lloh6:
	adrp	x9, _NAND_BBT_NO_OOB@GOTPAGE
Lloh7:
	ldr	x9, [x9, _NAND_BBT_NO_OOB@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x20]
	b	LBB0_3
LBB0_2:
Lloh9:
	adrp	x8, _NAND_SKIP_BBTSCAN@GOTPAGE
Lloh10:
	ldr	x8, [x8, _NAND_SKIP_BBTSCAN@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldr	w9, [x20, #4]
	orr	w8, w9, w8
	str	w8, [x20, #4]
LBB0_3:
	ldr	w8, [x22]
	sub	w9, w8, #134
	cmp	w9, #3
	b.hi	LBB0_10
; %bb.4:
Lloh12:
	adrp	x8, lJTI0_0@PAGE
Lloh13:
	add	x8, x8, lJTI0_0@PAGEOFF
	adr	x10, LBB0_5
	ldrb	w11, [x8, x9]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_5:
Lloh14:
	adrp	x8, _omap_read_buf_pref@GOTPAGE
Lloh15:
	ldr	x8, [x8, _omap_read_buf_pref@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
Lloh17:
	adrp	x9, _omap_write_buf_pref@GOTPAGE
Lloh18:
	ldr	x9, [x9, _omap_write_buf_pref@GOTPAGEOFF]
LBB0_6:
	ldr	w9, [x9]
	stp	w9, w8, [x20, #96]
LBB0_7:
	mov	x0, x22
	bl	_omap2_nand_ecc_check
	cbz	w0, LBB0_12
; %bb.8:
	ldr	w8, [x22, #12]
Lloh19:
	adrp	x9, _OMAP_ECC_HAM1_CODE_SW@GOTPAGE
Lloh20:
	ldr	x9, [x9, _OMAP_ECC_HAM1_CODE_SW@GOTPAGEOFF]
Lloh21:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_20
; %bb.9:
	mov	w23, #0
Lloh22:
	adrp	x8, _NAND_ECC_SOFT@GOTPAGE
Lloh23:
	ldr	x8, [x8, _NAND_ECC_SOFT@GOTPAGEOFF]
Lloh24:
	ldr	x8, [x8]
	str	x8, [x20, #64]
Lloh25:
	adrp	x8, _NAND_ECC_HAMMING@GOTPAGE
Lloh26:
	ldr	x8, [x8, _NAND_ECC_HAMMING@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
	str	w8, [x20, #88]
	b	LBB0_14
LBB0_10:
	str	x8, [sp]
Lloh28:
	adrp	x1, l_.str.8@PAGE
Lloh29:
	add	x1, x1, l_.str.8@PAGEOFF
LBB0_11:
	mov	x0, x19
	bl	_dev_err
LBB0_12:
Lloh30:
	adrp	x8, _EINVAL@GOTPAGE
Lloh31:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_13:
	ldr	w8, [x8]
	neg	w23, w8
LBB0_14:
	mov	x0, x23
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_15:
	mov	x0, x19
	mov	w1, #0
	bl	_platform_get_irq
	mov	x1, x0
	str	w1, [x22, #4]
	cmp	w1, #0
	b.le	LBB0_23
; %bb.16:
Lloh32:
	adrp	x25, _omap_nand_irq@GOTPAGE
Lloh33:
	ldr	x25, [x25, _omap_nand_irq@GOTPAGEOFF]
	ldr	w2, [x25]
Lloh34:
	adrp	x26, _IRQF_SHARED@GOTPAGE
Lloh35:
	ldr	x26, [x26, _IRQF_SHARED@GOTPAGEOFF]
	ldr	w3, [x26]
Lloh36:
	adrp	x4, l_.str.4@PAGE
Lloh37:
	add	x4, x4, l_.str.4@PAGEOFF
	mov	x0, x19
                                        ; kill: def $w1 killed $w1 killed $x1
	mov	x5, x22
	bl	_devm_request_irq
	cbz	w0, LBB0_27
; %bb.17:
	mov	x23, x0
	ldr	w8, [x22, #4]
	stp	x8, x23, [sp]
Lloh38:
	adrp	x1, l_.str.5@PAGE
Lloh39:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	str	wzr, [x22, #4]
                                        ; kill: def $w23 killed $w23 killed $x23 def $x23
	b	LBB0_14
LBB0_18:
	bl	_dma_cap_zero
Lloh40:
	adrp	x8, _DMA_SLAVE@GOTPAGE
Lloh41:
	ldr	x8, [x8, _DMA_SLAVE@GOTPAGEOFF]
Lloh42:
	ldr	w0, [x8]
	bl	_dma_cap_set
	ldr	w0, [x19]
Lloh43:
	adrp	x1, l_.str@PAGE
Lloh44:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dma_request_chan
	str	w0, [x22, #32]
	bl	_IS_ERR
	cbz	w0, LBB0_25
; %bb.19:
Lloh45:
	adrp	x1, l_.str.1@PAGE
Lloh46:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	ldr	w0, [x22, #32]
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	b	_PTR_ERR
LBB0_20:
	sub	w8, w8, #128
	cmp	w8, #5
	b.hi	LBB0_31
; %bb.21:
Lloh47:
	adrp	x9, lJTI0_1@PAGE
Lloh48:
	add	x9, x9, lJTI0_1@PAGEOFF
	adr	x10, LBB0_22
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_22:
Lloh49:
	adrp	x1, l_.str.9@PAGE
Lloh50:
	add	x1, x1, l_.str.9@PAGEOFF
	mov	x0, x19
	bl	_dev_info
Lloh51:
	adrp	x8, _NAND_ECC_HW@GOTPAGE
Lloh52:
	ldr	x8, [x8, _NAND_ECC_HW@GOTPAGEOFF]
Lloh53:
	ldr	x8, [x8]
	str	x8, [x20, #64]
Lloh54:
	adrp	x8, lCPI0_5@PAGE
Lloh55:
	ldr	d0, [x8, lCPI0_5@PAGEOFF]
	str	d0, [x20, #8]
	mov	w8, #1
	str	w8, [x20, #16]
Lloh56:
	adrp	x8, _omap_calculate_ecc@GOTPAGE
Lloh57:
	ldr	x8, [x8, _omap_calculate_ecc@GOTPAGEOFF]
Lloh58:
	ldr	x8, [x8]
	str	x8, [x20, #80]
Lloh59:
	adrp	x8, _omap_enable_hwecc@GOTPAGE
Lloh60:
	ldr	x8, [x8, _omap_enable_hwecc@GOTPAGEOFF]
Lloh61:
	ldr	x8, [x8]
Lloh62:
	adrp	x9, _omap_correct_data@GOTPAGE
Lloh63:
	ldr	x9, [x9, _omap_correct_data@GOTPAGEOFF]
Lloh64:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #48]
Lloh65:
	adrp	x1, _omap_ooblayout_ops@GOTPAGE
Lloh66:
	ldr	x1, [x1, _omap_ooblayout_ops@GOTPAGEOFF]
	mov	x0, x21
	bl	_mtd_set_ooblayout
	ldp	w8, w22, [x20, #4]
Lloh67:
	adrp	x9, _NAND_BUSWIDTH_16@GOTPAGE
Lloh68:
	ldr	x9, [x9, _NAND_BUSWIDTH_16@GOTPAGEOFF]
Lloh69:
	ldr	w9, [x9]
	tst	w9, w8
	csinc	w24, w24, wzr, ne
	b	LBB0_40
LBB0_23:
Lloh70:
	adrp	x1, l_.str.3@PAGE
Lloh71:
	add	x1, x1, l_.str.3@PAGEOFF
LBB0_24:
	mov	x0, x19
	bl	_dev_err
Lloh72:
	adrp	x8, _ENODEV@GOTPAGE
Lloh73:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
	b	LBB0_13
LBB0_25:
	add	x0, sp, #16
	mov	w1, #0
	mov	w2, #32
	bl	_memset
Lloh74:
	adrp	x8, _DMA_SLAVE_BUSWIDTH_4_BYTES@GOTPAGE
Lloh75:
	ldr	x8, [x8, _DMA_SLAVE_BUSWIDTH_4_BYTES@GOTPAGEOFF]
	ldp	w0, w9, [x22, #32]
	stp	w9, w9, [sp, #40]
Lloh76:
	ldr	x8, [x8]
	stp	x8, x8, [sp, #24]
	movi.2s	v0, #16
	str	d0, [sp, #16]
	add	x1, sp, #16
	bl	_dmaengine_slave_config
	cbz	w0, LBB0_30
; %bb.26:
	mov	x23, x0
	str	x23, [sp]
Lloh77:
	adrp	x1, l_.str.2@PAGE
Lloh78:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	b	LBB0_14
LBB0_27:
	ldr	x0, [x22, #24]
	mov	w1, #1
	bl	_platform_get_irq
	mov	x1, x0
	str	w1, [x22, #8]
	cmp	w1, #0
	b.le	LBB0_44
; %bb.28:
	ldr	w2, [x25]
	ldr	w3, [x26]
Lloh79:
	adrp	x4, l_.str.7@PAGE
Lloh80:
	add	x4, x4, l_.str.7@PAGEOFF
	mov	x0, x19
                                        ; kill: def $w1 killed $w1 killed $x1
	mov	x5, x22
	bl	_devm_request_irq
	cbz	w0, LBB0_45
; %bb.29:
	mov	x23, x0
	ldr	w8, [x22, #8]
	stp	x8, x23, [sp]
Lloh81:
	adrp	x1, l_.str.5@PAGE
Lloh82:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	str	wzr, [x22, #8]
                                        ; kill: def $w23 killed $w23 killed $x23 def $x23
	b	LBB0_14
LBB0_30:
Lloh83:
	adrp	x8, _omap_read_buf_dma_pref@GOTPAGE
Lloh84:
	ldr	x8, [x8, _omap_read_buf_dma_pref@GOTPAGEOFF]
Lloh85:
	ldr	w8, [x8]
Lloh86:
	adrp	x9, _omap_write_buf_dma_pref@GOTPAGE
Lloh87:
	ldr	x9, [x9, _omap_write_buf_dma_pref@GOTPAGEOFF]
	b	LBB0_6
LBB0_31:
Lloh88:
	adrp	x1, l_.str.17@PAGE
Lloh89:
	add	x1, x1, l_.str.17@PAGEOFF
	b	LBB0_11
LBB0_32:
Lloh90:
	adrp	x0, l_.str.13@PAGE
Lloh91:
	add	x0, x0, l_.str.13@PAGEOFF
	bl	_pr_info
Lloh92:
	adrp	x8, _NAND_ECC_HW@GOTPAGE
Lloh93:
	ldr	x8, [x8, _NAND_ECC_HW@GOTPAGEOFF]
Lloh94:
	ldr	x8, [x8]
	str	x8, [x20, #64]
Lloh95:
	adrp	x8, lCPI0_2@PAGE
Lloh96:
	ldr	d0, [x8, lCPI0_2@PAGEOFF]
	str	d0, [x20, #8]
	mov	w8, #8
	str	w8, [x20, #16]
Lloh97:
	adrp	x8, _omap_enable_hwecc_bch@GOTPAGE
Lloh98:
	ldr	x8, [x8, _omap_enable_hwecc_bch@GOTPAGEOFF]
Lloh99:
	ldr	x8, [x8]
Lloh100:
	adrp	x9, _nand_bch_correct_data@GOTPAGE
Lloh101:
	ldr	x9, [x9, _nand_bch_correct_data@GOTPAGEOFF]
Lloh102:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #48]
Lloh103:
	adrp	x8, _omap_calculate_ecc_bch_sw@GOTPAGE
Lloh104:
	ldr	x8, [x8, _omap_calculate_ecc_bch_sw@GOTPAGEOFF]
Lloh105:
	ldr	x8, [x8]
	str	x8, [x20, #80]
Lloh106:
	adrp	x1, _omap_sw_ooblayout_ops@GOTPAGE
Lloh107:
	ldr	x1, [x1, _omap_sw_ooblayout_ops@GOTPAGEOFF]
	mov	x0, x21
	bl	_mtd_set_ooblayout
	ldr	w22, [x20, #8]
	mov	x0, x21
	bl	_nand_bch_init
	str	x0, [x20, #72]
	cbnz	x0, LBB0_36
; %bb.33:
Lloh108:
	adrp	x1, l_.str.14@PAGE
Lloh109:
	add	x1, x1, l_.str.14@PAGEOFF
	b	LBB0_11
LBB0_34:
Lloh110:
	adrp	x0, l_.str.15@PAGE
Lloh111:
	add	x0, x0, l_.str.15@PAGEOFF
	bl	_pr_info
Lloh112:
	adrp	x8, _NAND_ECC_HW@GOTPAGE
Lloh113:
	ldr	x8, [x8, _NAND_ECC_HW@GOTPAGEOFF]
Lloh114:
	ldr	x8, [x8]
Lloh115:
	adrp	x9, lCPI0_1@PAGE
Lloh116:
	ldr	d0, [x9, lCPI0_1@PAGEOFF]
	str	d0, [x20, #8]
	mov	w9, #8
	str	w9, [x20, #16]
Lloh117:
	adrp	x9, _omap_enable_hwecc_bch@GOTPAGE
Lloh118:
	ldr	x9, [x9, _omap_enable_hwecc_bch@GOTPAGEOFF]
Lloh119:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #56]
Lloh120:
	adrp	x8, _omap_elm_correct_data@GOTPAGE
Lloh121:
	ldr	x8, [x8, _omap_elm_correct_data@GOTPAGEOFF]
Lloh122:
	adrp	x9, _omap_read_page_bch@GOTPAGE
Lloh123:
	ldr	x9, [x9, _omap_read_page_bch@GOTPAGEOFF]
Lloh124:
	ldr	x8, [x8]
Lloh125:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #40]
Lloh126:
	adrp	x8, _omap_write_page_bch@GOTPAGE
Lloh127:
	ldr	x8, [x8, _omap_write_page_bch@GOTPAGEOFF]
Lloh128:
	ldr	x8, [x8]
Lloh129:
	adrp	x9, _omap_write_subpage_bch@GOTPAGE
Lloh130:
	ldr	x9, [x9, _omap_write_subpage_bch@GOTPAGEOFF]
Lloh131:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #24]
Lloh132:
	adrp	x1, _omap_ooblayout_ops@GOTPAGE
Lloh133:
	ldr	x1, [x1, _omap_ooblayout_ops@GOTPAGEOFF]
	mov	x0, x21
	bl	_mtd_set_ooblayout
Lloh134:
	adrp	x8, _BCH8_ECC@GOTPAGE
Lloh135:
	ldr	x8, [x8, _BCH8_ECC@GOTPAGEOFF]
	b	LBB0_39
LBB0_35:
Lloh136:
	adrp	x0, l_.str.10@PAGE
Lloh137:
	add	x0, x0, l_.str.10@PAGEOFF
	bl	_pr_info
Lloh138:
	adrp	x8, _NAND_ECC_HW@GOTPAGE
Lloh139:
	ldr	x8, [x8, _NAND_ECC_HW@GOTPAGEOFF]
Lloh140:
	ldr	x8, [x8]
	str	x8, [x20, #64]
Lloh141:
	adrp	x8, lCPI0_4@PAGE
Lloh142:
	ldr	d0, [x8, lCPI0_4@PAGEOFF]
	str	d0, [x20, #8]
	mov	w8, #4
	str	w8, [x20, #16]
Lloh143:
	adrp	x8, _omap_enable_hwecc_bch@GOTPAGE
Lloh144:
	ldr	x8, [x8, _omap_enable_hwecc_bch@GOTPAGEOFF]
Lloh145:
	ldr	x8, [x8]
Lloh146:
	adrp	x9, _nand_bch_correct_data@GOTPAGE
Lloh147:
	ldr	x9, [x9, _nand_bch_correct_data@GOTPAGEOFF]
Lloh148:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #48]
Lloh149:
	adrp	x8, _omap_calculate_ecc_bch_sw@GOTPAGE
Lloh150:
	ldr	x8, [x8, _omap_calculate_ecc_bch_sw@GOTPAGEOFF]
Lloh151:
	ldr	x8, [x8]
	str	x8, [x20, #80]
Lloh152:
	adrp	x1, _omap_sw_ooblayout_ops@GOTPAGE
Lloh153:
	ldr	x1, [x1, _omap_sw_ooblayout_ops@GOTPAGEOFF]
	mov	x0, x21
	bl	_mtd_set_ooblayout
	ldr	w22, [x20, #8]
	mov	x0, x21
	bl	_nand_bch_init
	str	x0, [x20, #72]
	cbz	x0, LBB0_46
LBB0_36:
	add	w22, w22, #1
	b	LBB0_40
LBB0_37:
Lloh154:
	adrp	x0, l_.str.12@PAGE
Lloh155:
	add	x0, x0, l_.str.12@PAGEOFF
	bl	_pr_info
Lloh156:
	adrp	x8, _NAND_ECC_HW@GOTPAGE
Lloh157:
	ldr	x8, [x8, _NAND_ECC_HW@GOTPAGEOFF]
Lloh158:
	ldr	x8, [x8]
Lloh159:
	adrp	x9, lCPI0_3@PAGE
Lloh160:
	ldr	d0, [x9, lCPI0_3@PAGEOFF]
	str	d0, [x20, #8]
	mov	w9, #4
	str	w9, [x20, #16]
Lloh161:
	adrp	x9, _omap_enable_hwecc_bch@GOTPAGE
Lloh162:
	ldr	x9, [x9, _omap_enable_hwecc_bch@GOTPAGEOFF]
Lloh163:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #56]
Lloh164:
	adrp	x8, _omap_elm_correct_data@GOTPAGE
Lloh165:
	ldr	x8, [x8, _omap_elm_correct_data@GOTPAGEOFF]
Lloh166:
	adrp	x9, _omap_read_page_bch@GOTPAGE
Lloh167:
	ldr	x9, [x9, _omap_read_page_bch@GOTPAGEOFF]
Lloh168:
	ldr	x8, [x8]
Lloh169:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #40]
Lloh170:
	adrp	x8, _omap_write_page_bch@GOTPAGE
Lloh171:
	ldr	x8, [x8, _omap_write_page_bch@GOTPAGEOFF]
Lloh172:
	ldr	x8, [x8]
Lloh173:
	adrp	x9, _omap_write_subpage_bch@GOTPAGE
Lloh174:
	ldr	x9, [x9, _omap_write_subpage_bch@GOTPAGEOFF]
Lloh175:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #24]
Lloh176:
	adrp	x1, _omap_ooblayout_ops@GOTPAGE
Lloh177:
	ldr	x1, [x1, _omap_ooblayout_ops@GOTPAGEOFF]
	mov	x0, x21
	bl	_mtd_set_ooblayout
Lloh178:
	adrp	x8, _BCH4_ECC@GOTPAGE
Lloh179:
	ldr	x8, [x8, _BCH4_ECC@GOTPAGEOFF]
	b	LBB0_39
LBB0_38:
Lloh180:
	adrp	x0, l_.str.16@PAGE
Lloh181:
	add	x0, x0, l_.str.16@PAGEOFF
	bl	_pr_info
Lloh182:
	adrp	x8, _NAND_ECC_HW@GOTPAGE
Lloh183:
	ldr	x8, [x8, _NAND_ECC_HW@GOTPAGEOFF]
Lloh184:
	ldr	x8, [x8]
Lloh185:
	adrp	x9, lCPI0_0@PAGE
Lloh186:
	ldr	d0, [x9, lCPI0_0@PAGEOFF]
	str	d0, [x20, #8]
	mov	w9, #16
	str	w9, [x20, #16]
Lloh187:
	adrp	x9, _omap_enable_hwecc_bch@GOTPAGE
Lloh188:
	ldr	x9, [x9, _omap_enable_hwecc_bch@GOTPAGEOFF]
Lloh189:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #56]
Lloh190:
	adrp	x8, _omap_elm_correct_data@GOTPAGE
Lloh191:
	ldr	x8, [x8, _omap_elm_correct_data@GOTPAGEOFF]
Lloh192:
	adrp	x9, _omap_read_page_bch@GOTPAGE
Lloh193:
	ldr	x9, [x9, _omap_read_page_bch@GOTPAGEOFF]
Lloh194:
	ldr	x8, [x8]
Lloh195:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #40]
Lloh196:
	adrp	x8, _omap_write_page_bch@GOTPAGE
Lloh197:
	ldr	x8, [x8, _omap_write_page_bch@GOTPAGEOFF]
Lloh198:
	ldr	x8, [x8]
Lloh199:
	adrp	x9, _omap_write_subpage_bch@GOTPAGE
Lloh200:
	ldr	x9, [x9, _omap_write_subpage_bch@GOTPAGEOFF]
Lloh201:
	ldr	x9, [x9]
	stp	x9, x8, [x20, #24]
Lloh202:
	adrp	x1, _omap_ooblayout_ops@GOTPAGE
Lloh203:
	ldr	x1, [x1, _omap_ooblayout_ops@GOTPAGEOFF]
	mov	x0, x21
	bl	_mtd_set_ooblayout
Lloh204:
	adrp	x8, _BCH16_ECC@GOTPAGE
Lloh205:
	ldr	x8, [x8, _BCH16_ECC@GOTPAGEOFF]
LBB0_39:
	ldr	w0, [x22, #16]
	ldr	w1, [x8]
	ldr	w8, [x21]
	ldp	w22, w3, [x20, #8]
	sdiv	w2, w8, w3
	mov	x4, x22
	bl	_elm_config
	tbnz	w0, #31, LBB0_43
LBB0_40:
	ldr	w8, [x20, #12]
	ldp	w10, w9, [x21]
	sdiv	w8, w10, w8
	madd	w8, w8, w22, w24
	cmp	w9, w8
	b.ge	LBB0_42
; %bb.41:
	stp	x8, x9, [sp]
Lloh206:
	adrp	x1, l_.str.18@PAGE
Lloh207:
	add	x1, x1, l_.str.18@PAGEOFF
	b	LBB0_11
LBB0_42:
	mov	w23, #0
	b	LBB0_14
LBB0_43:
	mov	x23, x0
	b	LBB0_14
LBB0_44:
Lloh208:
	adrp	x1, l_.str.6@PAGE
Lloh209:
	add	x1, x1, l_.str.6@PAGEOFF
	b	LBB0_24
LBB0_45:
Lloh210:
	adrp	x8, _omap_read_buf_irq_pref@GOTPAGE
Lloh211:
	ldr	x8, [x8, _omap_read_buf_irq_pref@GOTPAGEOFF]
Lloh212:
	ldr	w8, [x8]
Lloh213:
	adrp	x9, _omap_write_buf_irq_pref@GOTPAGE
Lloh214:
	ldr	x9, [x9, _omap_write_buf_irq_pref@GOTPAGEOFF]
	b	LBB0_6
LBB0_46:
Lloh215:
	adrp	x1, l_.str.11@PAGE
Lloh216:
	add	x1, x1, l_.str.11@PAGEOFF
	b	LBB0_11
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpLdrGot	Lloh34, Lloh35
	.loh AdrpLdrGot	Lloh32, Lloh33
	.loh AdrpAdd	Lloh38, Lloh39
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpAdd	Lloh47, Lloh48
	.loh AdrpLdrGotLdr	Lloh67, Lloh68, Lloh69
	.loh AdrpLdrGot	Lloh65, Lloh66
	.loh AdrpLdrGotLdr	Lloh62, Lloh63, Lloh64
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpLdr	Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpAdd	Lloh49, Lloh50
	.loh AdrpAdd	Lloh70, Lloh71
	.loh AdrpLdrGot	Lloh72, Lloh73
	.loh AdrpLdrGotLdr	Lloh74, Lloh75, Lloh76
	.loh AdrpAdd	Lloh77, Lloh78
	.loh AdrpAdd	Lloh79, Lloh80
	.loh AdrpAdd	Lloh81, Lloh82
	.loh AdrpLdrGot	Lloh86, Lloh87
	.loh AdrpLdrGotLdr	Lloh83, Lloh84, Lloh85
	.loh AdrpAdd	Lloh88, Lloh89
	.loh AdrpLdrGot	Lloh106, Lloh107
	.loh AdrpLdrGotLdr	Lloh103, Lloh104, Lloh105
	.loh AdrpLdrGotLdr	Lloh100, Lloh101, Lloh102
	.loh AdrpLdrGotLdr	Lloh97, Lloh98, Lloh99
	.loh AdrpLdr	Lloh95, Lloh96
	.loh AdrpLdrGotLdr	Lloh92, Lloh93, Lloh94
	.loh AdrpAdd	Lloh90, Lloh91
	.loh AdrpAdd	Lloh108, Lloh109
	.loh AdrpLdrGot	Lloh134, Lloh135
	.loh AdrpLdrGot	Lloh132, Lloh133
	.loh AdrpLdrGotLdr	Lloh129, Lloh130, Lloh131
	.loh AdrpLdrGotLdr	Lloh126, Lloh127, Lloh128
	.loh AdrpLdrGotLdr	Lloh122, Lloh123, Lloh125
	.loh AdrpLdrGotLdr	Lloh120, Lloh121, Lloh124
	.loh AdrpLdrGotLdr	Lloh117, Lloh118, Lloh119
	.loh AdrpLdr	Lloh115, Lloh116
	.loh AdrpLdrGotLdr	Lloh112, Lloh113, Lloh114
	.loh AdrpAdd	Lloh110, Lloh111
	.loh AdrpLdrGot	Lloh152, Lloh153
	.loh AdrpLdrGotLdr	Lloh149, Lloh150, Lloh151
	.loh AdrpLdrGotLdr	Lloh146, Lloh147, Lloh148
	.loh AdrpLdrGotLdr	Lloh143, Lloh144, Lloh145
	.loh AdrpLdr	Lloh141, Lloh142
	.loh AdrpLdrGotLdr	Lloh138, Lloh139, Lloh140
	.loh AdrpAdd	Lloh136, Lloh137
	.loh AdrpLdrGot	Lloh178, Lloh179
	.loh AdrpLdrGot	Lloh176, Lloh177
	.loh AdrpLdrGotLdr	Lloh173, Lloh174, Lloh175
	.loh AdrpLdrGotLdr	Lloh170, Lloh171, Lloh172
	.loh AdrpLdrGotLdr	Lloh166, Lloh167, Lloh169
	.loh AdrpLdrGotLdr	Lloh164, Lloh165, Lloh168
	.loh AdrpLdrGotLdr	Lloh161, Lloh162, Lloh163
	.loh AdrpLdr	Lloh159, Lloh160
	.loh AdrpLdrGotLdr	Lloh156, Lloh157, Lloh158
	.loh AdrpAdd	Lloh154, Lloh155
	.loh AdrpLdrGot	Lloh204, Lloh205
	.loh AdrpLdrGot	Lloh202, Lloh203
	.loh AdrpLdrGotLdr	Lloh199, Lloh200, Lloh201
	.loh AdrpLdrGotLdr	Lloh196, Lloh197, Lloh198
	.loh AdrpLdrGotLdr	Lloh192, Lloh193, Lloh195
	.loh AdrpLdrGotLdr	Lloh190, Lloh191, Lloh194
	.loh AdrpLdrGotLdr	Lloh187, Lloh188, Lloh189
	.loh AdrpLdr	Lloh185, Lloh186
	.loh AdrpLdrGotLdr	Lloh182, Lloh183, Lloh184
	.loh AdrpAdd	Lloh180, Lloh181
	.loh AdrpAdd	Lloh206, Lloh207
	.loh AdrpAdd	Lloh208, Lloh209
	.loh AdrpLdrGot	Lloh213, Lloh214
	.loh AdrpLdrGotLdr	Lloh210, Lloh211, Lloh212
	.loh AdrpAdd	Lloh215, Lloh216
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_5-LBB0_5)>>2
	.byte	(LBB0_15-LBB0_5)>>2
	.byte	(LBB0_18-LBB0_5)>>2
	.byte	(LBB0_7-LBB0_5)>>2
lJTI0_1:
	.byte	(LBB0_22-LBB0_22)>>2
	.byte	(LBB0_32-LBB0_22)>>2
	.byte	(LBB0_34-LBB0_22)>>2
	.byte	(LBB0_35-LBB0_22)>>2
	.byte	(LBB0_37-LBB0_22)>>2
	.byte	(LBB0_38-LBB0_22)>>2
                                        ; -- End function
	.comm	_BADBLOCK_MARKER_LENGTH,4,2     ; @BADBLOCK_MARKER_LENGTH
	.comm	_NAND_BBT_USE_FLASH,4,2         ; @NAND_BBT_USE_FLASH
	.comm	_NAND_BBT_NO_OOB,4,2            ; @NAND_BBT_NO_OOB
	.comm	_NAND_SKIP_BBTSCAN,4,2          ; @NAND_SKIP_BBTSCAN
	.comm	_omap_read_buf_pref,4,2         ; @omap_read_buf_pref
	.comm	_omap_write_buf_pref,4,2        ; @omap_write_buf_pref
	.comm	_DMA_SLAVE,4,2                  ; @DMA_SLAVE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"rxtx"

l_.str.1:                               ; @.str.1
	.asciz	"DMA engine request failed\n"

	.comm	_DMA_SLAVE_BUSWIDTH_4_BYTES,8,3 ; @DMA_SLAVE_BUSWIDTH_4_BYTES
l_.str.2:                               ; @.str.2
	.asciz	"DMA engine slave config failed: %d\n"

	.comm	_omap_read_buf_dma_pref,4,2     ; @omap_read_buf_dma_pref
	.comm	_omap_write_buf_dma_pref,4,2    ; @omap_write_buf_dma_pref
l_.str.3:                               ; @.str.3
	.asciz	"Error getting fifo IRQ\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_omap_nand_irq,4,2              ; @omap_nand_irq
	.comm	_IRQF_SHARED,4,2                ; @IRQF_SHARED
l_.str.4:                               ; @.str.4
	.asciz	"gpmc-nand-fifo"

l_.str.5:                               ; @.str.5
	.asciz	"Requesting IRQ %d, error %d\n"

l_.str.6:                               ; @.str.6
	.asciz	"Error getting IRQ count\n"

l_.str.7:                               ; @.str.7
	.asciz	"gpmc-nand-count"

	.comm	_omap_read_buf_irq_pref,4,2     ; @omap_read_buf_irq_pref
	.comm	_omap_write_buf_irq_pref,4,2    ; @omap_write_buf_irq_pref
l_.str.8:                               ; @.str.8
	.asciz	"xfer_type %d not supported!\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_OMAP_ECC_HAM1_CODE_SW,4,2      ; @OMAP_ECC_HAM1_CODE_SW
	.comm	_NAND_ECC_SOFT,8,3              ; @NAND_ECC_SOFT
	.comm	_NAND_ECC_HAMMING,4,2           ; @NAND_ECC_HAMMING
l_.str.9:                               ; @.str.9
	.asciz	"nand: using OMAP_ECC_HAM1_CODE_HW\n"

	.comm	_NAND_ECC_HW,8,3                ; @NAND_ECC_HW
	.comm	_omap_calculate_ecc,8,3         ; @omap_calculate_ecc
	.comm	_omap_enable_hwecc,8,3          ; @omap_enable_hwecc
	.comm	_omap_correct_data,8,3          ; @omap_correct_data
	.comm	_omap_ooblayout_ops,4,2         ; @omap_ooblayout_ops
	.comm	_NAND_BUSWIDTH_16,4,2           ; @NAND_BUSWIDTH_16
l_.str.10:                              ; @.str.10
	.asciz	"nand: using OMAP_ECC_BCH4_CODE_HW_DETECTION_SW\n"

	.comm	_omap_enable_hwecc_bch,8,3      ; @omap_enable_hwecc_bch
	.comm	_nand_bch_correct_data,8,3      ; @nand_bch_correct_data
	.comm	_omap_calculate_ecc_bch_sw,8,3  ; @omap_calculate_ecc_bch_sw
	.comm	_omap_sw_ooblayout_ops,4,2      ; @omap_sw_ooblayout_ops
l_.str.11:                              ; @.str.11
	.asciz	"Unable to use BCH library\n"

l_.str.12:                              ; @.str.12
	.asciz	"nand: using OMAP_ECC_BCH4_CODE_HW ECC scheme\n"

	.comm	_omap_elm_correct_data,8,3      ; @omap_elm_correct_data
	.comm	_omap_read_page_bch,8,3         ; @omap_read_page_bch
	.comm	_omap_write_page_bch,8,3        ; @omap_write_page_bch
	.comm	_omap_write_subpage_bch,8,3     ; @omap_write_subpage_bch
	.comm	_BCH4_ECC,4,2                   ; @BCH4_ECC
l_.str.13:                              ; @.str.13
	.asciz	"nand: using OMAP_ECC_BCH8_CODE_HW_DETECTION_SW\n"

l_.str.14:                              ; @.str.14
	.asciz	"unable to use BCH library\n"

l_.str.15:                              ; @.str.15
	.asciz	"nand: using OMAP_ECC_BCH8_CODE_HW ECC scheme\n"

	.comm	_BCH8_ECC,4,2                   ; @BCH8_ECC
l_.str.16:                              ; @.str.16
	.asciz	"Using OMAP_ECC_BCH16_CODE_HW ECC scheme\n"

	.comm	_BCH16_ECC,4,2                  ; @BCH16_ECC
l_.str.17:                              ; @.str.17
	.asciz	"Invalid or unsupported ECC scheme\n"

l_.str.18:                              ; @.str.18
	.asciz	"Not enough OOB bytes: required = %d, available=%d\n"

	.no_dead_strip	_omap_nand_attach_chip
.subsections_via_symbols
