	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stor_init
_stor_init:                             ## @stor_init
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_devs_no@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	je	LBB0_10
## %bb.1:
	jle	LBB0_8
## %bb.2:
	xorl	%ebx, %ebx
	movq	_DEV_TYP_STOR@GOTPCREL(%rip), %r15
	movq	_stor_info_no@GOTPCREL(%rip), %r12
	movq	_UB_MAX_DEV@GOTPCREL(%rip), %r13
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_4 Depth=1
	incl	%ebx
	cmpl	(%r14), %ebx
	jge	LBB0_8
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ebx, %edi
	callq	_ub_dev_get
	testq	%rax, %rax
	je	LBB0_3
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	(%rax), %ecx
	testl	%ecx, (%r15)
	je	LBB0_3
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movslq	(%r12), %rsi
	cmpl	(%r13), %esi
	jge	LBB0_12
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	_stor_info@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	leaq	(%rsi,%rsi,2), %rsi
	movl	%ebx, (%rdx,%rsi,8)
	movslq	(%r12), %rsi
	leaq	(%rsi,%rsi,2), %rsi
	movq	$0, 16(%rdx,%rsi,8)
	movl	%ecx, 4(%rdx,%rsi,8)
	movl	8(%rax), %ecx
	movslq	(%r12), %rsi
	leaq	(%rsi,%rsi,2), %rsi
	movl	%ecx, 12(%rdx,%rsi,8)
	movl	4(%rax), %eax
	movslq	(%r12), %rcx
	leaq	(%rcx,%rcx,2), %rcx
	movl	%eax, 8(%rdx,%rcx,8)
	incl	(%r12)
	jmp	LBB0_3
LBB0_8:
	movq	_stor_info_no@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	testl	%esi, %esi
	je	LBB0_11
## %bb.9:
	leaq	L_.str.3(%rip), %rdi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_debugf
	jmp	LBB0_14
LBB0_10:
	leaq	L_str(%rip), %rdi
	callq	_puts
	jmp	LBB0_13
LBB0_11:
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_debugf
	jmp	LBB0_13
LBB0_12:
	leaq	L_.str.1(%rip), %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	xorl	%eax, %eax
	callq	_printf
LBB0_13:
	movl	$-1, %ebx
LBB0_14:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_devs_no,4,2                    ## @devs_no
	.comm	_DEV_TYP_STOR,4,2               ## @DEV_TYP_STOR
	.comm	_stor_info_no,4,2               ## @stor_info_no
	.comm	_UB_MAX_DEV,4,2                 ## @UB_MAX_DEV
	.section	__TEXT,__cstring,cstring_literals
L_.str.1:                               ## @.str.1
	.asciz	"Too many storage devices: %d\n"

	.comm	_stor_info,8,3                  ## @stor_info
L_.str.2:                               ## @.str.2
	.asciz	"No storage devices\n"

L_.str.3:                               ## @.str.3
	.asciz	"storage devices found: %d\n"

L_str:                                  ## @str
	.asciz	"No U-Boot devices! Really enumerated?"

	.no_dead_strip	_stor_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stor_init
_stor_init:                             ; @stor_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.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
Lloh0:
	adrp	x20, _devs_no@GOTPAGE
Lloh1:
	ldr	x20, [x20, _devs_no@GOTPAGEOFF]
	ldr	w8, [x20]
	cbz	w8, LBB0_10
; %bb.1:
Lloh2:
	adrp	x21, _stor_info_no@GOTPAGE
Lloh3:
	ldr	x21, [x21, _stor_info_no@GOTPAGEOFF]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.2:
	mov	w19, #0
Lloh4:
	adrp	x22, _DEV_TYP_STOR@GOTPAGE
Lloh5:
	ldr	x22, [x22, _DEV_TYP_STOR@GOTPAGEOFF]
Lloh6:
	adrp	x23, _UB_MAX_DEV@GOTPAGE
Lloh7:
	ldr	x23, [x23, _UB_MAX_DEV@GOTPAGEOFF]
	mov	w24, #24
Lloh8:
	adrp	x25, _stor_info@GOTPAGE
Lloh9:
	ldr	x25, [x25, _stor_info@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	w19, w19, #1
	ldr	w8, [x20]
	cmp	w19, w8
	b.ge	LBB0_8
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_ub_dev_get
	cbz	x0, LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x0]
	ldr	w9, [x22]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldrsw	x9, [x21]
	ldr	w10, [x23]
	cmp	w9, w10
	b.ge	LBB0_12
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x10, [x25]
	mul	x9, x9, x24
	str	w19, [x10, x9]
	ldrsw	x9, [x21]
	madd	x9, x9, x24, x10
	str	xzr, [x9, #16]
	str	w8, [x9, #4]
	ldrsw	x8, [x21]
	madd	x8, x8, x24, x10
	ldp	w11, w9, [x0, #4]
	str	w9, [x8, #12]
	ldrsw	x8, [x21]
	madd	x8, x8, x24, x10
	str	w11, [x8, #8]
	ldr	w8, [x21]
	add	w8, w8, #1
	str	w8, [x21]
	b	LBB0_3
LBB0_8:
	ldr	w8, [x21]
	cbz	w8, LBB0_11
; %bb.9:
	str	x8, [sp]
Lloh10:
	adrp	x0, l_.str.3@PAGE
Lloh11:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_debugf
	mov	w0, #0
	b	LBB0_14
LBB0_10:
Lloh12:
	adrp	x0, l_str@PAGE
Lloh13:
	add	x0, x0, l_str@PAGEOFF
	bl	_puts
	b	LBB0_13
LBB0_11:
Lloh14:
	adrp	x0, l_.str.2@PAGE
Lloh15:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_debugf
	b	LBB0_13
LBB0_12:
	str	x9, [sp]
Lloh16:
	adrp	x0, l_.str.1@PAGE
Lloh17:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_printf
LBB0_13:
	mov	w0, #-1
LBB0_14:
	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
	add	sp, sp, #96
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_devs_no,4,2                    ; @devs_no
	.comm	_DEV_TYP_STOR,4,2               ; @DEV_TYP_STOR
	.comm	_stor_info_no,4,2               ; @stor_info_no
	.comm	_UB_MAX_DEV,4,2                 ; @UB_MAX_DEV
	.section	__TEXT,__cstring,cstring_literals
l_.str.1:                               ; @.str.1
	.asciz	"Too many storage devices: %d\n"

	.comm	_stor_info,8,3                  ; @stor_info
l_.str.2:                               ; @.str.2
	.asciz	"No storage devices\n"

l_.str.3:                               ; @.str.3
	.asciz	"storage devices found: %d\n"

l_str:                                  ; @str
	.asciz	"No U-Boot devices! Really enumerated?"

	.no_dead_strip	_stor_init
.subsections_via_symbols
