	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function s5pcxx_nand_correct_data
_s5pcxx_nand_correct_data:              ## @s5pcxx_nand_correct_data
	.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	%rsi, -72(%rbp)                 ## 8-byte Spill
	movq	(%rdi), %rax
	movq	(%rax), %r14
	movq	_S5P_NFECCSTAT@GOTPCREL(%rip), %rbx
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rbx), %rdi
	addq	(%r14), %rdi
	callq	_readl
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movq	_S5P_NFECCSECSTAT@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	(%r14), %rdi
	callq	_readl
	movl	%eax, %ebx
	andl	$31, %ebx
	movq	_S5P_NFECCERL@GOTPCREL(%rip), %r13
	movq	(%r13), %rdi
	addq	(%r14), %rdi
	callq	_readl
	movl	%eax, %r12d
	movq	(%r14), %rax
	movq	(%r13), %rcx
	leaq	(%rax,%rcx), %rdi
	addq	$4, %rdi
	callq	_readl
                                        ## kill: def $eax killed $eax def $rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	(%r14), %rax
	movq	(%r13), %rcx
	leaq	(%rax,%rcx), %rdi
	addq	$8, %rdi
	callq	_readl
                                        ## kill: def $eax killed $eax def $rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	(%r14), %rax
	movq	(%r13), %rcx
	leaq	(%rax,%rcx), %rdi
	addq	$12, %rdi
	callq	_readl
                                        ## kill: def $eax killed $eax def $rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	_S5P_NFECCERP@GOTPCREL(%rip), %r13
	movq	(%r13), %rdi
	addq	(%r14), %rdi
	callq	_readl
	movl	%eax, %r15d
	movq	(%r14), %rax
	movq	(%r13), %rcx
	leaq	(%rax,%rcx), %rdi
	addq	$4, %rdi
	callq	_readl
	cmpl	$8, %ebx
	ja	LBB0_12
## %bb.3:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rbx,4), %rdx
	addq	%rcx, %rdx
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	jmpq	*%rdx
LBB0_4:
	movl	%eax, %ecx
	shrl	$24, %ecx
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
                                        ## kill: def $edx killed $edx killed $rdx def $rdx
	shrl	$16, %edx
	andl	$1023, %edx                     ## imm = 0x3FF
	xorl	%ecx, (%rsi,%rdx,4)
LBB0_5:
	movl	%eax, %ecx
	shrl	$16, %ecx
	movzbl	%cl, %ecx
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	andl	$1023, %edx                     ## imm = 0x3FF
	xorl	%ecx, (%rsi,%rdx,4)
LBB0_6:
	movzbl	%ah, %ecx
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
                                        ## kill: def $edx killed $edx killed $rdx def $rdx
	shrl	$16, %edx
	andl	$1023, %edx                     ## imm = 0x3FF
	xorl	%ecx, (%rsi,%rdx,4)
LBB0_7:
	movzbl	%al, %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	andl	$1023, %ecx                     ## imm = 0x3FF
	xorl	%eax, (%rsi,%rcx,4)
LBB0_8:
	movl	%r15d, %eax
	shrl	$24, %eax
	movl	%edi, %ecx
	shrl	$16, %ecx
	andl	$1023, %ecx                     ## imm = 0x3FF
	xorl	%eax, (%rsi,%rcx,4)
LBB0_9:
	movl	%r15d, %eax
	shrl	$16, %eax
	movzbl	%al, %eax
	andl	$1023, %edi                     ## imm = 0x3FF
	xorl	%eax, (%rsi,%rdi,4)
LBB0_10:
	movl	%r15d, %eax
	movzbl	%ah, %eax
	movl	%r12d, %ecx
	shrl	$16, %ecx
	andl	$1023, %ecx                     ## imm = 0x3FF
	xorl	%eax, (%rsi,%rcx,4)
LBB0_11:
	movzbl	%r15b, %eax
	andl	$1023, %r12d                    ## imm = 0x3FF
	xorl	%eax, (%rsi,%r12,4)
	xorl	%ebx, %ebx
LBB0_13:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %esi
	callq	_printk
	movl	$-1, %ebx
	jmp	LBB0_13
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_13, LBB0_13-LJTI0_0
.set L0_0_set_11, LBB0_11-LJTI0_0
.set L0_0_set_10, LBB0_10-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_4, LBB0_4-LJTI0_0
LJTI0_0:
	.long	L0_0_set_13
	.long	L0_0_set_11
	.long	L0_0_set_10
	.long	L0_0_set_9
	.long	L0_0_set_8
	.long	L0_0_set_7
	.long	L0_0_set_6
	.long	L0_0_set_5
	.long	L0_0_set_4
	.end_data_region
                                        ## -- End function
	.comm	_S5P_NFECCSTAT,8,3              ## @S5P_NFECCSTAT
	.comm	_S5P_NFECCSECSTAT,8,3           ## @S5P_NFECCSECSTAT
	.comm	_S5P_NFECCERL,8,3               ## @S5P_NFECCERL
	.comm	_S5P_NFECCERP,8,3               ## @S5P_NFECCERP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ECC uncorrectable error detected:%d\n"

	.no_dead_strip	_s5pcxx_nand_correct_data
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function s5pcxx_nand_correct_data
_s5pcxx_nand_correct_data:              ; @s5pcxx_nand_correct_data
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x1
	ldr	x8, [x0]
	ldr	x26, [x8]
Lloh0:
	adrp	x20, _S5P_NFECCSTAT@GOTPAGE
Lloh1:
	ldr	x20, [x20, _S5P_NFECCSTAT@GOTPAGEOFF]
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x26]
	ldr	x9, [x20]
	add	x0, x9, x8
	bl	_readl
	tbnz	w0, #31, LBB0_1
; %bb.2:
	ldr	x8, [x26]
Lloh2:
	adrp	x9, _S5P_NFECCSECSTAT@GOTPAGE
Lloh3:
	ldr	x9, [x9, _S5P_NFECCSECSTAT@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	and	w22, w0, #0x1f
	ldr	x8, [x26]
Lloh5:
	adrp	x23, _S5P_NFECCERL@GOTPAGE
Lloh6:
	ldr	x23, [x23, _S5P_NFECCERL@GOTPAGEOFF]
	ldr	x9, [x23]
	add	x0, x9, x8
	bl	_readl
	mov	x20, x0
	ldr	x8, [x26]
	ldr	x9, [x23]
	add	x8, x8, x9
	add	x0, x8, #4
	bl	_readl
	mov	x21, x0
	ldr	x8, [x26]
	ldr	x9, [x23]
	add	x8, x8, x9
	add	x0, x8, #8
	bl	_readl
	mov	x24, x0
	ldr	x8, [x26]
	ldr	x9, [x23]
	add	x8, x8, x9
	add	x0, x8, #12
	bl	_readl
	mov	x25, x0
	ldr	x8, [x26]
Lloh7:
	adrp	x27, _S5P_NFECCERP@GOTPAGE
Lloh8:
	ldr	x27, [x27, _S5P_NFECCERP@GOTPAGEOFF]
	ldr	x9, [x27]
	add	x0, x9, x8
	bl	_readl
	mov	x23, x0
	ldr	x8, [x26]
	ldr	x9, [x27]
	add	x8, x8, x9
	add	x0, x8, #4
	bl	_readl
	cmp	w22, #8
	b.hi	LBB0_13
; %bb.3:
Lloh9:
	adrp	x8, lJTI0_0@PAGE
Lloh10:
	add	x8, x8, lJTI0_0@PAGEOFF
	adr	x9, LBB0_4
	ldrb	w10, [x8, x22]
	add	x9, x9, x10, lsl #2
	br	x9
LBB0_4:
	ubfx	w8, w25, #16, #10
	lsl	x8, x8, #2
	ldr	w9, [x19, x8]
	eor	w9, w9, w0, lsr #24
	str	w9, [x19, x8]
LBB0_5:
	ubfx	w8, w0, #16, #8
	and	w9, w25, #0x3ff
	lsl	x9, x9, #2
	ldr	w10, [x19, x9]
	eor	w8, w10, w8
	str	w8, [x19, x9]
LBB0_6:
	ubfx	w8, w0, #8, #8
	ubfx	w9, w24, #16, #10
	lsl	x9, x9, #2
	ldr	w10, [x19, x9]
	eor	w8, w10, w8
	str	w8, [x19, x9]
LBB0_7:
	and	w8, w0, #0xff
	and	w9, w24, #0x3ff
	lsl	x9, x9, #2
	ldr	w10, [x19, x9]
	eor	w8, w10, w8
	str	w8, [x19, x9]
LBB0_8:
	ubfx	w8, w21, #16, #10
	lsl	x8, x8, #2
	ldr	w9, [x19, x8]
	eor	w9, w9, w23, lsr #24
	str	w9, [x19, x8]
LBB0_9:
	ubfx	w8, w23, #16, #8
	and	w9, w21, #0x3ff
	lsl	x9, x9, #2
	ldr	w10, [x19, x9]
	eor	w8, w10, w8
	str	w8, [x19, x9]
LBB0_10:
	ubfx	w8, w23, #8, #8
	ubfx	w9, w20, #16, #10
	lsl	x9, x9, #2
	ldr	w10, [x19, x9]
	eor	w8, w10, w8
	str	w8, [x19, x9]
LBB0_11:
	mov	w22, #0
	and	w8, w23, #0xff
	and	w9, w20, #0x3ff
	lsl	x9, x9, #2
	ldr	w10, [x19, x9]
	eor	w8, w10, w8
	str	w8, [x19, x9]
LBB0_12:
	mov	x0, x22
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_13:
Lloh11:
	adrp	x0, l_.str@PAGE
Lloh12:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x22
	bl	_printk
	mov	w22, #-1
	b	LBB0_12
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_12-LBB0_4)>>2
	.byte	(LBB0_11-LBB0_4)>>2
	.byte	(LBB0_10-LBB0_4)>>2
	.byte	(LBB0_9-LBB0_4)>>2
	.byte	(LBB0_8-LBB0_4)>>2
	.byte	(LBB0_7-LBB0_4)>>2
	.byte	(LBB0_6-LBB0_4)>>2
	.byte	(LBB0_5-LBB0_4)>>2
	.byte	(LBB0_4-LBB0_4)>>2
                                        ; -- End function
	.comm	_S5P_NFECCSTAT,8,3              ; @S5P_NFECCSTAT
	.comm	_S5P_NFECCSECSTAT,8,3           ; @S5P_NFECCSECSTAT
	.comm	_S5P_NFECCERL,8,3               ; @S5P_NFECCERL
	.comm	_S5P_NFECCERP,8,3               ; @S5P_NFECCERP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ECC uncorrectable error detected:%d\n"

	.no_dead_strip	_s5pcxx_nand_correct_data
.subsections_via_symbols
