	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nvm_get_bb_meta
_nvm_get_bb_meta:                       ## @nvm_get_bb_meta
	.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	$152, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r14
	movl	%edx, %ebx
	movq	%rdi, %r12
	movq	%rsi, -96(%rbp)
	movq	-96(%rbp), %rax
	movq	%rax, 16(%rsp)
	movaps	-112(%rbp), %xmm0
	movups	%xmm0, (%rsp)
	leaq	-88(%rbp), %rdi
	movq	%r12, %rsi
	callq	_dev_to_generic_addr
	movq	-72(%rbp), %rax
	movq	%rax, -96(%rbp)
	movups	-88(%rbp), %xmm0
	movaps	%xmm0, -112(%rbp)
	cmpq	$0, -112(%rbp)
	jne	LBB0_1
## %bb.3:
	movl	8(%r12), %r15d
	movl	%ebx, %eax
	cltd
	idivl	%r15d
	testl	%edx, %edx
	je	LBB0_4
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_22:
	movl	%ebx, %eax
	addq	$152, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	imull	12(%r12), %r15d
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r15d, %edi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movl	-104(%rbp), %edx
	movl	16(%r12), %ecx
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	cmpl	%ecx, %edx
	jge	LBB0_20
## %bb.7:
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movl	20(%r12), %eax
	jmp	LBB0_8
LBB0_18:                                ##   in Loop: Header=BB0_8 Depth=1
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	incl	%edx
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	cmpl	%ecx, %edx
	jge	LBB0_19
LBB0_8:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_9 Depth 2
	movl	-100(%rbp), %r13d
	cmpl	%eax, %r13d
	jge	LBB0_18
	.p2align	4, 0x90
LBB0_9:                                 ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	testl	%ebx, %ebx
	je	LBB0_10
## %bb.11:                              ##   in Loop: Header=BB0_9 Depth=2
	movl	%ebx, -60(%rbp)                 ## 4-byte Spill
	movq	%r14, %rbx
	movq	$0, -72(%rbp)
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, -80(%rbp)
	movl	%r13d, -76(%rbp)
	movq	-72(%rbp), %rax
	movq	%rax, 16(%rsp)
	movups	-88(%rbp), %xmm0
	movups	%xmm0, (%rsp)
	leaq	-168(%rbp), %rdi
	movq	%r12, %rsi
	callq	_generic_to_dev_addr
	movq	-152(%rbp), %rax
	movq	%rax, -128(%rbp)
	movups	-168(%rbp), %xmm0
	movaps	%xmm0, -144(%rbp)
	movq	(%r12), %rax
	movq	-128(%rbp), %rcx
	movq	%rcx, 16(%rsp)
	movaps	-144(%rbp), %xmm0
	movups	%xmm0, (%rsp)
	movq	%r12, %rdi
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rsi
	callq	*(%rax)
	testl	%eax, %eax
	jne	LBB0_12
## %bb.13:                              ##   in Loop: Header=BB0_9 Depth=2
	movq	-72(%rbp), %rax
	movq	%rax, 16(%rsp)
	movups	-88(%rbp), %xmm0
	movups	%xmm0, (%rsp)
	movq	%r12, %rdi
	movq	%r14, %rsi
	movl	%r15d, %edx
	movq	%rbx, %r14
	movq	%rbx, %rcx
	callq	_nvm_bb_to_chunk
	testl	%eax, %eax
	jne	LBB0_14
## %bb.16:                              ##   in Loop: Header=BB0_9 Depth=2
	movslq	8(%r12), %rax
	leaq	(%r14,%rax,4), %r14
	movl	-60(%rbp), %ebx                 ## 4-byte Reload
	subl	%eax, %ebx
	incl	%r13d
	movl	20(%r12), %eax
	cmpl	%eax, %r13d
	jl	LBB0_9
## %bb.17:                              ##   in Loop: Header=BB0_8 Depth=1
	movl	16(%r12), %ecx
	jmp	LBB0_18
LBB0_5:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_10:
	xorl	%ebx, %ebx
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	jmp	LBB0_21
LBB0_12:
	movl	%eax, %ebx
	movq	%r14, %rax
	jmp	LBB0_21
LBB0_14:
	movl	%eax, %ebx
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	jmp	LBB0_21
LBB0_19:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
LBB0_20:
	xorl	%ebx, %ebx
LBB0_21:
	movq	%rax, %rdi
	callq	_kfree
	jmp	LBB0_22
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_nvm_get_bb_meta
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nvm_get_bb_meta
_nvm_get_bb_meta:                       ; @nvm_get_bb_meta
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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, x3
	mov	x20, x2
	mov	x21, x0
	str	x1, [sp, #16]
	add	x8, sp, #24
	mov	x1, sp
	bl	_dev_to_generic_addr
	ldr	x8, [sp, #24]
	cbnz	x8, LBB0_2
; %bb.1:
	ldr	w8, [x21, #8]
	sdiv	w9, w20, w8
	msub	w9, w9, w8, w20
	cbz	w9, LBB0_5
LBB0_2:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_3:
	ldr	w8, [x8]
	neg	w24, w8
LBB0_4:
	mov	x0, x24
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
LBB0_5:
	ldp	w25, w26, [sp, #32]
	ldr	w9, [x21, #12]
	mul	w23, w9, w8
Lloh2:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x23
	bl	_kmalloc
	cbz	x0, LBB0_17
; %bb.6:
	mov	x22, x0
	ldr	w9, [x21, #16]
	cmp	w25, w9
	b.ge	LBB0_16
; %bb.7:
	ldr	w8, [x21, #20]
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	add	w25, w25, #1
	cmp	w25, w9
	b.ge	LBB0_16
LBB0_9:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_11 Depth 2
	cmp	w26, w8
	b.ge	LBB0_8
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x27, x26
LBB0_11:                                ;   Parent Loop BB0_9 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	cbz	w20, LBB0_16
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=2
	stp	w25, w27, [sp, #8]
	str	xzr, [sp, #16]
	add	x8, sp, #24
	mov	x1, sp
	mov	x0, x21
	bl	_generic_to_dev_addr
	ldr	x8, [x21]
	ldr	x8, [x8]
	ldur	q0, [sp, #24]
	str	q0, [sp]
	ldr	x9, [sp, #40]
	str	x9, [sp, #16]
	mov	x1, sp
	mov	x0, x21
	mov	x2, x22
	blr	x8
	cbnz	w0, LBB0_18
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=2
	stp	w25, w27, [sp, #8]
	str	xzr, [sp, #16]
	mov	x1, sp
	mov	x0, x21
	mov	x2, x22
	mov	x3, x23
	mov	x4, x19
	bl	_nvm_bb_to_chunk
	cbnz	w0, LBB0_18
; %bb.14:                               ;   in Loop: Header=BB0_11 Depth=2
	ldrsw	x8, [x21, #8]
	add	x19, x19, x8, lsl #2
	sub	w20, w20, w8
	add	w27, w27, #1
	ldr	w8, [x21, #20]
	cmp	w27, w8
	b.lt	LBB0_11
; %bb.15:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w9, [x21, #16]
	b	LBB0_8
LBB0_16:
	mov	w24, #0
	b	LBB0_19
LBB0_17:
Lloh5:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_3
LBB0_18:
	mov	x24, x0
LBB0_19:
	mov	x0, x22
	bl	_kfree
	b	LBB0_4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_nvm_get_bb_meta
.subsections_via_symbols
