	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function scan_peb
_scan_peb:                              ## @scan_peb
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, -80(%rbp)                 ## 4-byte Spill
	movl	%edx, %r12d
	movq	%rdi, %r13
	movq	64(%rsi), %r14
	movq	%rsi, -56(%rbp)                 ## 8-byte Spill
	movq	72(%rsi), %r15
	movq	%r14, %rdi
	callq	_ubi_get_vid_hdr
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	leaq	L_.str(%rip), %rdi
	movl	%r12d, %esi
	callq	_dbg_bld
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_ubi_io_is_bad
	testl	%eax, %eax
	js	LBB0_3
## %bb.1:
	je	LBB0_6
## %bb.2:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	incl	(%rax)
	xorl	%ebx, %ebx
	jmp	LBB0_4
LBB0_6:
	movq	%r13, %rdi
	movl	%r12d, %esi
	movq	%r15, %rdx
	xorl	%ecx, %ecx
	callq	_ubi_io_read_ec_hdr
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_4
## %bb.7:
	leal	-128(%rbx), %eax
	cmpl	$4, %eax
	ja	LBB0_14
## %bb.8:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_9:
	movq	_UBI_UNKNOWN@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movb	$1, %al
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	%ebx, %ecx
	movl	$1, %ebx
	movb	$1, %al
	movl	%eax, -76(%rbp)                 ## 4-byte Spill
LBB0_10:
	movl	%ecx, %r15d
	movq	%r13, %rdi
	movl	%r12d, %esi
	movq	%r14, %rdx
	xorl	%ecx, %ecx
	callq	_ubi_io_read_vid_hdr
                                        ## kill: def $eax killed $eax def $rax
	testl	%eax, %eax
	js	LBB0_27
## %bb.11:
	leal	-128(%rax), %ecx
	cmpl	$4, %ecx
	ja	LBB0_34
## %bb.12:
	leaq	LJTI0_1(%rip), %rax
	movslq	(%rax,%rcx,4), %rcx
	addq	%rax, %rcx
	jmpq	*%rcx
LBB0_13:
	movq	_UBI_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	jmp	LBB0_38
LBB0_14:
	testl	%ebx, %ebx
	jne	LBB0_24
## %bb.15:
	xorl	%esi, %esi
	jmp	LBB0_21
LBB0_16:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	incl	4(%rdi)
	movq	_UBI_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movslq	%eax, %rcx
	leaq	52(%rdi), %rax
	movq	%rax, (%rsp)
	movl	%r12d, %esi
	movl	%ecx, %edx
	movq	%rcx, %r8
LBB0_17:
	movl	$1, %r9d
	callq	_add_to_list
	jmp	LBB0_5
LBB0_18:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	incl	4(%rdi)
	movq	_UBI_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movslq	%eax, %rcx
	leaq	52(%rdi), %rax
	movq	%rax, (%rsp)
	movl	%r12d, %esi
	movl	%ecx, %edx
	movq	%rcx, %r8
LBB0_19:
	xorl	%r9d, %r9d
	callq	_add_to_list
	jmp	LBB0_5
LBB0_20:
	movl	$1, %ebx
	movb	$1, %sil
LBB0_21:
	movq	(%r15), %rcx
	movq	_UBI_VERSION@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	cmpq	%rdx, %rcx
	jne	LBB0_25
## %bb.22:
	movl	%esi, -76(%rbp)                 ## 4-byte Spill
	movl	12(%r15), %edi
	callq	_be64_to_cpu
	movq	_UBI_MAX_ERASECOUNTER@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	cmpq	%rdx, %rax
	jle	LBB0_28
## %bb.23:
	leaq	L_.str.3(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r13, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	xorl	%eax, %eax
	callq	_ubi_err
	jmp	LBB0_33
LBB0_24:
	leaq	L_.str.1(%rip), %rsi
	xorl	%r14d, %r14d
	movq	%r13, %rdi
	movl	%ebx, %edx
	xorl	%eax, %eax
	callq	_ubi_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
	movl	%r14d, %ebx
	jmp	LBB0_4
LBB0_25:
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r13, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
                                        ## kill: def $ecx killed $ecx killed $rcx
LBB0_26:
	xorl	%eax, %eax
	callq	_ubi_err
	jmp	LBB0_36
LBB0_27:
	movl	%eax, %ebx
	jmp	LBB0_4
LBB0_28:
	movl	8(%r15), %edi
	callq	_be32_to_cpu
	movl	(%r13), %r8d
	testl	%r8d, %r8d
	jne	LBB0_30
## %bb.29:
	movl	%eax, (%r13)
	movl	%eax, %r8d
LBB0_30:
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	testl	%eax, %eax
	je	LBB0_57
## %bb.31:
	movl	$0, %ecx
	cmpl	%eax, %r8d
	je	LBB0_10
## %bb.32:
	leaq	L_.str.4(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r13, %rdi
	movl	%eax, %edx
	movl	%r12d, %ecx
	xorl	%eax, %eax
	callq	_ubi_err
LBB0_33:
	movq	%r15, %rdi
	callq	_ubi_dump_ec_hdr
	jmp	LBB0_36
LBB0_34:
	testl	%eax, %eax
	je	LBB0_41
## %bb.35:
	leaq	L_.str.5(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r13, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_ubi_err
LBB0_36:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_4
LBB0_37:
	movl	-76(%rbp), %edx                 ## 4-byte Reload
	orb	-44(%rbp), %dl                  ## 1-byte Folded Reload
	movq	_UBI_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	cmpb	$1, %dl
	jne	LBB0_58
LBB0_38:
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	jmp	LBB0_39
LBB0_40:
	movl	$1, %ebx
LBB0_41:
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movl	8(%rax), %edi
	callq	_be32_to_cpu
	movl	%eax, %r14d
	movq	_UBI_MAX_VOLUMES@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	jle	LBB0_43
## %bb.42:
	movl	%r14d, %edi
	callq	_vol_ignored
	testl	%eax, %eax
	je	LBB0_65
LBB0_43:
	cmpb	$0, -44(%rbp)                   ## 1-byte Folded Reload
	je	LBB0_45
## %bb.44:
	leaq	L_.str.10(%rip), %rsi
	movq	%r13, %rdi
	movl	%r12d, %edx
	callq	_ubi_warn
LBB0_45:
	movl	%r14d, %edi
	callq	_ubi_is_fm_vol
	testq	%rax, %rax
	je	LBB0_56
## %bb.46:
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	%r12d, %esi
	movq	-72(%rbp), %rdx                 ## 8-byte Reload
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rcx
	callq	_add_fastmap
	jmp	LBB0_60
LBB0_47:
	cmpl	$131, %r15d
	jne	LBB0_49
## %bb.48:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	incl	8(%rax)
LBB0_49:
	cmpl	$0, -80(%rbp)                   ## 4-byte Folded Reload
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	je	LBB0_51
## %bb.50:
	movl	$1, 12(%r14)
LBB0_51:
	cmpb	$0, -44(%rbp)                   ## 1-byte Folded Reload
	je	LBB0_53
LBB0_52:
	movq	_UBI_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
LBB0_39:
	leaq	52(%r14), %rax
	movq	%rax, (%rsp)
	movq	%r14, %rdi
	movl	%r12d, %esi
	movl	%ecx, %edx
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %r8
	movl	$1, %r9d
LBB0_59:
	callq	_add_to_list
LBB0_60:
	movl	%eax, %ebx
	testl	%eax, %eax
	setne	%al
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	orb	%al, %cl
	jne	LBB0_4
## %bb.61:
	addq	%r15, 16(%r14)
	incl	24(%r14)
	cmpq	32(%r14), %r15
	jle	LBB0_63
## %bb.62:
	movq	%r15, 32(%r14)
LBB0_63:
	xorl	%ebx, %ebx
	cmpq	40(%r14), %r15
	jge	LBB0_4
## %bb.64:
	movq	%r15, 40(%r14)
	jmp	LBB0_4
LBB0_53:
	movq	%r13, %rdi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movl	%r12d, %edx
	callq	_check_corruption
	testl	%eax, %eax
	js	LBB0_3
## %bb.54:
	je	LBB0_52
## %bb.55:
	movq	%r14, %rdi
	movl	%r12d, %esi
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdx
	callq	_add_corrupted
	jmp	LBB0_60
LBB0_3:
	movl	%eax, %ebx
LBB0_4:
	movl	%ebx, %eax
LBB0_5:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_56:
	movq	%r13, %rdi
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rsi
	movl	%r12d, %edx
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rcx
	movq	-72(%rbp), %r8                  ## 8-byte Reload
	movl	%ebx, %r9d
	callq	_ubi_add_to_av
	jmp	LBB0_60
LBB0_57:
	xorl	%ecx, %ecx
	jmp	LBB0_10
LBB0_58:
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	leaq	56(%r14), %rax
	movq	%rax, (%rsp)
	movq	%r14, %rdi
	movl	%r12d, %esi
	movl	%ecx, %edx
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %r8
	xorl	%r9d, %r9d
	jmp	LBB0_59
LBB0_65:
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	movl	4(%r15), %edi
	callq	_be32_to_cpu
	movl	$-133, %edx
	addl	(%r15), %edx
	cmpl	$3, %edx
	ja	LBB0_43
## %bb.66:
	leaq	LJTI0_2(%rip), %rcx
	movslq	(%rcx,%rdx,4), %rdx
	addq	%rcx, %rdx
	jmpq	*%rdx
LBB0_67:
	leaq	L_.str.7(%rip), %rsi
	movq	%r13, %rdi
	movl	%r14d, %edx
	movl	%eax, %ecx
	callq	_ubi_msg
	movl	$1, 4(%r13)
	jmp	LBB0_43
LBB0_68:
	leaq	L_.str.9(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r13, %rdi
	movl	%r14d, %edx
	movl	%eax, %ecx
	jmp	LBB0_26
LBB0_69:
	leaq	L_.str.8(%rip), %rsi
	movq	%r13, %rdi
	movl	%r14d, %edx
	movl	%eax, %ecx
	movl	%eax, %ebx
	callq	_ubi_msg
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	leaq	48(%rdi), %rax
	movq	%rax, (%rsp)
	movl	%r12d, %esi
	movl	%r14d, %edx
	movl	%ebx, %ecx
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	jmp	LBB0_19
LBB0_70:
	leaq	L_.str.6(%rip), %rsi
	movq	%r13, %rdi
	movl	%r14d, %edx
	movl	%eax, %ecx
	movl	%eax, %ebx
	callq	_ubi_msg
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	leaq	52(%rdi), %rax
	movq	%rax, (%rsp)
	movl	%r12d, %esi
	movl	%r14d, %edx
	movl	%ebx, %ecx
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	jmp	LBB0_17
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_16, LBB0_16-LJTI0_0
.set L0_0_set_18, LBB0_18-LJTI0_0
.set L0_0_set_20, LBB0_20-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
LJTI0_0:
	.long	L0_0_set_16
	.long	L0_0_set_18
	.long	L0_0_set_20
	.long	L0_0_set_9
	.long	L0_0_set_9
.set L0_1_set_13, LBB0_13-LJTI0_1
.set L0_1_set_37, LBB0_37-LJTI0_1
.set L0_1_set_40, LBB0_40-LJTI0_1
.set L0_1_set_47, LBB0_47-LJTI0_1
.set L0_1_set_49, LBB0_49-LJTI0_1
LJTI0_1:
	.long	L0_1_set_13
	.long	L0_1_set_37
	.long	L0_1_set_40
	.long	L0_1_set_47
	.long	L0_1_set_49
.set L0_2_set_67, LBB0_67-LJTI0_2
.set L0_2_set_68, LBB0_68-LJTI0_2
.set L0_2_set_69, LBB0_69-LJTI0_2
.set L0_2_set_70, LBB0_70-LJTI0_2
LJTI0_2:
	.long	L0_2_set_67
	.long	L0_2_set_68
	.long	L0_2_set_69
	.long	L0_2_set_70
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"scan PEB %d"

	.comm	_UBI_UNKNOWN,4,2                ## @UBI_UNKNOWN
L_.str.1:                               ## @.str.1
	.asciz	"'ubi_io_read_ec_hdr()' returned unknown code %d"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_UBI_VERSION,8,3                ## @UBI_VERSION
L_.str.2:                               ## @.str.2
	.asciz	"this UBI version is %d, image version is %d"

	.comm	_UBI_MAX_ERASECOUNTER,8,3       ## @UBI_MAX_ERASECOUNTER
L_.str.3:                               ## @.str.3
	.asciz	"erase counter overflow, max is %d"

L_.str.4:                               ## @.str.4
	.asciz	"bad image sequence number %d in PEB %d, expected %d"

L_.str.5:                               ## @.str.5
	.asciz	"'ubi_io_read_vid_hdr()' returned unknown code %d"

	.comm	_UBI_MAX_VOLUMES,4,2            ## @UBI_MAX_VOLUMES
L_.str.6:                               ## @.str.6
	.asciz	"\"delete\" compatible internal volume %d:%d found, will remove it"

L_.str.7:                               ## @.str.7
	.asciz	"read-only compatible internal volume %d:%d found, switch to read-only mode"

L_.str.8:                               ## @.str.8
	.asciz	"\"preserve\" compatible internal volume %d:%d found"

L_.str.9:                               ## @.str.9
	.asciz	"incompatible internal volume %d:%d found"

L_.str.10:                              ## @.str.10
	.asciz	"valid VID header but corrupted EC header at PEB %d"

	.no_dead_strip	_scan_peb
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function scan_peb
_scan_peb:                              ; @scan_peb
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x25, x3
	mov	x21, x2
	mov	x19, x1
	mov	x23, x0
	ldp	x26, x27, [x1, #64]
	mov	x0, x26
	bl	_ubi_get_vid_hdr
	mov	x24, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x21
	bl	_dbg_bld
	mov	x0, x23
	mov	x1, x21
	bl	_ubi_io_is_bad
	mov	x22, x0
	tbnz	w0, #31, LBB0_3
; %bb.1:
	cbz	w22, LBB0_4
; %bb.2:
	mov	w22, #0
	ldr	w8, [x19]
	add	w8, w8, #1
	str	w8, [x19]
LBB0_3:
	mov	x0, x22
	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
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_4:
	mov	x0, x23
	mov	x1, x21
	mov	x2, x27
	mov	w3, #0
	bl	_ubi_io_read_ec_hdr
	mov	x22, x0
	tbnz	w0, #31, LBB0_3
; %bb.5:
	sub	w8, w22, #128
	cmp	w8, #4
	b.hi	LBB0_12
; %bb.6:
Lloh2:
	adrp	x9, lJTI0_0@PAGE
Lloh3:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_7
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_7:
Lloh4:
	adrp	x8, _UBI_UNKNOWN@GOTPAGE
Lloh5:
	ldr	x8, [x8, _UBI_UNKNOWN@GOTPAGEOFF]
Lloh6:
	ldrsw	x8, [x8]
	str	x8, [sp, #24]                   ; 8-byte Folded Spill
	mov	w8, #1
	str	w8, [sp, #20]                   ; 4-byte Folded Spill
	mov	x20, x22
	mov	w22, #1
	mov	w28, #1
LBB0_8:
	mov	x0, x23
	mov	x1, x21
	mov	x2, x26
	mov	w3, #0
	bl	_ubi_io_read_vid_hdr
	mov	x2, x0
	tbnz	w0, #31, LBB0_25
; %bb.9:
	sub	w8, w2, #128
	cmp	w8, #4
	b.hi	LBB0_33
; %bb.10:
Lloh7:
	adrp	x9, lJTI0_1@PAGE
Lloh8:
	add	x9, x9, lJTI0_1@PAGEOFF
	adr	x10, LBB0_11
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_11:
Lloh9:
	adrp	x8, _UBI_UNKNOWN@GOTPAGE
Lloh10:
	ldr	x8, [x8, _UBI_UNKNOWN@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	add	x6, x19, #52
	mov	x0, x19
	mov	x1, x21
	mov	x3, x2
	ldr	x20, [sp, #24]                  ; 8-byte Folded Reload
	mov	x4, x20
	mov	w5, #1
	bl	_add_to_list
	mov	x22, x0
	cmp	w0, #0
	cset	w8, ne
	ldr	w9, [sp, #20]                   ; 4-byte Folded Reload
	orr	w8, w9, w8
	tbnz	w8, #0, LBB0_3
	b	LBB0_58
LBB0_12:
	cbnz	w22, LBB0_22
; %bb.13:
	mov	w28, #0
	b	LBB0_19
LBB0_14:
	ldr	w8, [x19, #4]
	add	w8, w8, #1
	str	w8, [x19, #4]
Lloh12:
	adrp	x8, _UBI_UNKNOWN@GOTPAGE
Lloh13:
	ldr	x8, [x8, _UBI_UNKNOWN@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
	sxtw	x4, w2
	add	x6, x19, #52
	mov	x0, x19
	mov	x1, x21
	mov	x3, x2
	mov	w5, #1
	b	LBB0_17
LBB0_15:
	ldr	w8, [x19, #4]
	add	w8, w8, #1
	str	w8, [x19, #4]
Lloh15:
	adrp	x8, _UBI_UNKNOWN@GOTPAGE
Lloh16:
	ldr	x8, [x8, _UBI_UNKNOWN@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
	sxtw	x4, w2
	add	x6, x19, #52
	mov	x0, x19
	mov	x1, x21
	mov	x3, x2
LBB0_16:
	mov	w5, #0
LBB0_17:
	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
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	b	_add_to_list
LBB0_18:
	mov	w28, #1
	mov	w22, #1
LBB0_19:
	ldr	x8, [x27]
Lloh18:
	adrp	x9, _UBI_VERSION@GOTPAGE
Lloh19:
	ldr	x9, [x9, _UBI_VERSION@GOTPAGEOFF]
Lloh20:
	ldr	x2, [x9]
	cmp	x8, x2
	b.ne	LBB0_23
; %bb.20:
	ldr	w0, [x27, #12]
	bl	_be64_to_cpu
Lloh21:
	adrp	x8, _UBI_MAX_ERASECOUNTER@GOTPAGE
Lloh22:
	ldr	x8, [x8, _UBI_MAX_ERASECOUNTER@GOTPAGEOFF]
Lloh23:
	ldr	x2, [x8]
	cmp	x0, x2
	b.le	LBB0_26
; %bb.21:
Lloh24:
	adrp	x1, l_.str.3@PAGE
Lloh25:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x23
                                        ; kill: def $w2 killed $w2 killed $x2
	b	LBB0_31
LBB0_22:
Lloh26:
	adrp	x1, l_.str.1@PAGE
Lloh27:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x23
	mov	x2, x22
	b	LBB0_24
LBB0_23:
	str	x8, [sp]
Lloh28:
	adrp	x1, l_.str.2@PAGE
Lloh29:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x23
                                        ; kill: def $w2 killed $w2 killed $x2
LBB0_24:
	bl	_ubi_err
	b	LBB0_32
LBB0_25:
	mov	x22, x2
	b	LBB0_3
LBB0_26:
	mov	x20, x0
	ldr	w0, [x27, #8]
	bl	_be32_to_cpu
	mov	x2, x0
	ldr	w8, [x23]
	cbnz	w8, LBB0_28
; %bb.27:
	str	w2, [x23]
	mov	x8, x2
LBB0_28:
	str	x20, [sp, #24]                  ; 8-byte Folded Spill
	mov	w20, #0
	str	wzr, [sp, #20]                  ; 4-byte Folded Spill
	cbz	w2, LBB0_8
; %bb.29:
	cmp	w8, w2
	b.eq	LBB0_8
; %bb.30:
	stp	x21, x8, [sp]
Lloh30:
	adrp	x1, l_.str.4@PAGE
Lloh31:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x23
LBB0_31:
	bl	_ubi_err
	mov	x0, x27
	bl	_ubi_dump_ec_hdr
LBB0_32:
Lloh32:
	adrp	x8, _EINVAL@GOTPAGE
Lloh33:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_3
LBB0_33:
	cbz	w2, LBB0_38
; %bb.34:
Lloh35:
	adrp	x1, l_.str.5@PAGE
Lloh36:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x23
	b	LBB0_24
LBB0_35:
	ldr	w23, [sp, #20]                  ; 4-byte Folded Reload
	orr	w8, w23, w28
Lloh37:
	adrp	x9, _UBI_UNKNOWN@GOTPAGE
Lloh38:
	ldr	x9, [x9, _UBI_UNKNOWN@GOTPAGEOFF]
Lloh39:
	ldr	w2, [x9]
	cmp	w8, #1
	b.ne	LBB0_56
; %bb.36:
	add	x6, x19, #52
	mov	x0, x19
	mov	x1, x21
	mov	x3, x2
	ldr	x20, [sp, #24]                  ; 8-byte Folded Reload
	mov	x4, x20
	mov	w5, #1
	b	LBB0_57
LBB0_37:
	mov	w22, #1
LBB0_38:
	ldr	w0, [x24, #8]
	bl	_be32_to_cpu
	mov	x25, x0
Lloh40:
	adrp	x8, _UBI_MAX_VOLUMES@GOTPAGE
Lloh41:
	ldr	x8, [x8, _UBI_MAX_VOLUMES@GOTPAGEOFF]
Lloh42:
	ldr	w8, [x8]
	cmp	w0, w8
	ldr	x20, [sp, #24]                  ; 8-byte Folded Reload
	b.le	LBB0_40
; %bb.39:
	mov	x0, x25
	bl	_vol_ignored
	cbz	w0, LBB0_63
LBB0_40:
	ldr	w26, [sp, #20]                  ; 4-byte Folded Reload
	cbz	w26, LBB0_42
; %bb.41:
Lloh43:
	adrp	x1, l_.str.10@PAGE
Lloh44:
	add	x1, x1, l_.str.10@PAGEOFF
	mov	x0, x23
	mov	x2, x21
	bl	_ubi_warn
LBB0_42:
	mov	x0, x25
	bl	_ubi_is_fm_vol
	cbz	x0, LBB0_54
; %bb.43:
	mov	x0, x19
	mov	x1, x21
	mov	x2, x24
	mov	x3, x20
	bl	_add_fastmap
	b	LBB0_55
LBB0_44:
	cmp	w20, #131
	b.ne	LBB0_46
; %bb.45:
	ldr	w8, [x19, #8]
	add	w8, w8, #1
	str	w8, [x19, #8]
LBB0_46:
	cbz	w25, LBB0_48
; %bb.47:
	mov	w8, #1
	str	w8, [x19, #12]
LBB0_48:
	ldr	x20, [sp, #24]                  ; 8-byte Folded Reload
	ldr	w25, [sp, #20]                  ; 4-byte Folded Reload
	tbz	w25, #0, LBB0_50
LBB0_49:
Lloh45:
	adrp	x8, _UBI_UNKNOWN@GOTPAGE
Lloh46:
	ldr	x8, [x8, _UBI_UNKNOWN@GOTPAGEOFF]
Lloh47:
	ldr	w2, [x8]
	add	x6, x19, #52
	mov	x0, x19
	mov	x1, x21
	mov	x3, x2
	mov	x4, x20
	mov	w5, #1
	bl	_add_to_list
	b	LBB0_53
LBB0_50:
	mov	x0, x23
	mov	x1, x24
	mov	x2, x21
	bl	_check_corruption
	mov	x22, x0
	tbnz	w0, #31, LBB0_3
; %bb.51:
	cbz	w22, LBB0_49
; %bb.52:
	mov	x0, x19
	mov	x1, x21
	mov	x2, x20
	bl	_add_corrupted
LBB0_53:
	mov	x22, x0
	cmp	w0, #0
	cset	w8, ne
	orr	w8, w25, w8
	tbnz	w8, #0, LBB0_3
	b	LBB0_58
LBB0_54:
	mov	x0, x23
	mov	x1, x19
	mov	x2, x21
	mov	x3, x20
	mov	x4, x24
	mov	x5, x22
	bl	_ubi_add_to_av
LBB0_55:
	mov	x22, x0
	cmp	w0, #0
	cset	w8, ne
	orr	w8, w26, w8
	tbnz	w8, #0, LBB0_3
	b	LBB0_58
LBB0_56:
	add	x6, x19, #56
	mov	x0, x19
	mov	x1, x21
	mov	x3, x2
	ldr	x20, [sp, #24]                  ; 8-byte Folded Reload
	mov	x4, x20
	mov	w5, #0
LBB0_57:
	bl	_add_to_list
	mov	x22, x0
	cmp	w0, #0
	cset	w8, ne
	orr	w8, w23, w8
	tbnz	w8, #0, LBB0_3
LBB0_58:
	ldr	x8, [x19, #16]
	add	x8, x8, x20
	str	x8, [x19, #16]
	ldr	w8, [x19, #24]
	add	w8, w8, #1
	str	w8, [x19, #24]
	ldr	x8, [x19, #32]
	cmp	x20, x8
	b.le	LBB0_60
; %bb.59:
	str	x20, [x19, #32]
LBB0_60:
	ldr	x8, [x19, #40]
	cmp	x20, x8
	b.ge	LBB0_62
; %bb.61:
	mov	w22, #0
	str	x20, [x19, #40]
	b	LBB0_3
LBB0_62:
	mov	w22, #0
	b	LBB0_3
LBB0_63:
	ldr	w0, [x24, #4]
	bl	_be32_to_cpu
	ldr	w8, [x24]
	sub	w8, w8, #133
	cmp	w8, #3
	b.hi	LBB0_40
; %bb.64:
	mov	x26, x0
Lloh48:
	adrp	x9, lJTI0_2@PAGE
Lloh49:
	add	x9, x9, lJTI0_2@PAGEOFF
	adr	x10, LBB0_65
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_65:
Lloh50:
	adrp	x1, l_.str.7@PAGE
Lloh51:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	x0, x23
	mov	x2, x25
	mov	x3, x26
	bl	_ubi_msg
	mov	w8, #1
	str	w8, [x23, #4]
	b	LBB0_40
LBB0_66:
	str	x26, [sp]
Lloh52:
	adrp	x1, l_.str.9@PAGE
Lloh53:
	add	x1, x1, l_.str.9@PAGEOFF
	mov	x0, x23
	mov	x2, x25
	b	LBB0_24
LBB0_67:
Lloh54:
	adrp	x1, l_.str.8@PAGE
Lloh55:
	add	x1, x1, l_.str.8@PAGEOFF
	mov	x0, x23
	mov	x2, x25
	mov	x3, x26
	bl	_ubi_msg
	add	x6, x19, #48
	mov	x0, x19
	mov	x1, x21
	mov	x2, x25
	mov	x3, x26
	mov	x4, x20
	b	LBB0_16
LBB0_68:
Lloh56:
	adrp	x1, l_.str.6@PAGE
Lloh57:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x23
	mov	x2, x25
	mov	x3, x26
	bl	_ubi_msg
	add	x6, x19, #52
	mov	x0, x19
	mov	x1, x21
	mov	x2, x25
	mov	x3, x26
	mov	x4, x20
	mov	w5, #1
	b	LBB0_17
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpAdd	Lloh48, Lloh49
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpAdd	Lloh52, Lloh53
	.loh AdrpAdd	Lloh54, Lloh55
	.loh AdrpAdd	Lloh56, Lloh57
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_14-LBB0_7)>>2
	.byte	(LBB0_15-LBB0_7)>>2
	.byte	(LBB0_18-LBB0_7)>>2
	.byte	(LBB0_7-LBB0_7)>>2
	.byte	(LBB0_7-LBB0_7)>>2
lJTI0_1:
	.byte	(LBB0_11-LBB0_11)>>2
	.byte	(LBB0_35-LBB0_11)>>2
	.byte	(LBB0_37-LBB0_11)>>2
	.byte	(LBB0_44-LBB0_11)>>2
	.byte	(LBB0_46-LBB0_11)>>2
lJTI0_2:
	.byte	(LBB0_65-LBB0_65)>>2
	.byte	(LBB0_66-LBB0_65)>>2
	.byte	(LBB0_67-LBB0_65)>>2
	.byte	(LBB0_68-LBB0_65)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"scan PEB %d"

	.comm	_UBI_UNKNOWN,4,2                ; @UBI_UNKNOWN
l_.str.1:                               ; @.str.1
	.asciz	"'ubi_io_read_ec_hdr()' returned unknown code %d"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_UBI_VERSION,8,3                ; @UBI_VERSION
l_.str.2:                               ; @.str.2
	.asciz	"this UBI version is %d, image version is %d"

	.comm	_UBI_MAX_ERASECOUNTER,8,3       ; @UBI_MAX_ERASECOUNTER
l_.str.3:                               ; @.str.3
	.asciz	"erase counter overflow, max is %d"

l_.str.4:                               ; @.str.4
	.asciz	"bad image sequence number %d in PEB %d, expected %d"

l_.str.5:                               ; @.str.5
	.asciz	"'ubi_io_read_vid_hdr()' returned unknown code %d"

	.comm	_UBI_MAX_VOLUMES,4,2            ; @UBI_MAX_VOLUMES
l_.str.6:                               ; @.str.6
	.asciz	"\"delete\" compatible internal volume %d:%d found, will remove it"

l_.str.7:                               ; @.str.7
	.asciz	"read-only compatible internal volume %d:%d found, switch to read-only mode"

l_.str.8:                               ; @.str.8
	.asciz	"\"preserve\" compatible internal volume %d:%d found"

l_.str.9:                               ; @.str.9
	.asciz	"incompatible internal volume %d:%d found"

l_.str.10:                              ; @.str.10
	.asciz	"valid VID header but corrupted EC header at PEB %d"

	.no_dead_strip	_scan_peb
.subsections_via_symbols
