	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function parse_afs_partitions
_parse_afs_partitions:                  ## @parse_afs_partitions
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpq	$0, (%rdi)
	jle	LBB0_19
## %bb.1:
	movq	%rdi, %r14
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	xorl	%r12d, %r12d
	xorl	%r15d, %r15d
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_afs_is_v1
	leaq	8(%r12), %r13
	xorl	%r14d, %r14d
	testq	%rax, %rax
	setne	%r14b
	cmoveq	%r12, %r13
	addl	%ebx, %r14d
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%r15, %rsi
	callq	_afs_is_v2
	leaq	8(%r13), %r12
	xorl	%ebx, %ebx
	testq	%rax, %rax
	setne	%bl
	cmoveq	%r13, %r12
	addl	%r14d, %ebx
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	addq	8(%r14), %r15
	cmpq	(%r14), %r15
	jl	LBB0_2
## %bb.3:
	testl	%ebx, %ebx
	je	LBB0_19
## %bb.4:
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_20
## %bb.5:
	movq	%rax, %r15
	cmpq	$0, (%r14)
	jle	LBB0_21
## %bb.6:
	xorl	%ebx, %ebx
	xorl	%r12d, %r12d
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_9 Depth=1
	incl	%ebx
LBB0_8:                                 ##   in Loop: Header=BB0_9 Depth=1
	addq	8(%r14), %r12
	cmpq	(%r14), %r12
	jge	LBB0_22
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_afs_is_v1
	testq	%rax, %rax
	je	LBB0_12
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movslq	%ebx, %rax
	leaq	(%r15,%rax,8), %rdx
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_afs_parse_v1_partition
	testl	%eax, %eax
	jne	LBB0_14
## %bb.11:                              ##   in Loop: Header=BB0_9 Depth=1
	incl	%ebx
LBB0_12:                                ##   in Loop: Header=BB0_9 Depth=1
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_afs_is_v2
	testq	%rax, %rax
	je	LBB0_8
## %bb.13:                              ##   in Loop: Header=BB0_9 Depth=1
	movslq	%ebx, %rax
	leaq	(%r15,%rax,8), %rdx
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_afs_parse_v2_partition
	testl	%eax, %eax
	je	LBB0_7
LBB0_14:
	movl	%eax, %r13d
	testl	%ebx, %ebx
	js	LBB0_17
## %bb.15:
	movl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_16:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r15,%rbx,8), %rdi
	callq	_kfree
	addq	$-1, %rbx
	jb	LBB0_16
LBB0_17:
	movq	%r15, %rdi
	callq	_kfree
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	$0, (%rax)
	jmp	LBB0_23
LBB0_19:
	xorl	%r13d, %r13d
	jmp	LBB0_23
LBB0_20:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r13d, %r13d
	subl	(%rax), %r13d
	jmp	LBB0_23
LBB0_21:
	xorl	%ebx, %ebx
LBB0_22:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	%r15, (%rax)
	movl	%ebx, %r13d
LBB0_23:
	movl	%r13d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_parse_afs_partitions
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function parse_afs_partitions
_parse_afs_partitions:                  ; @parse_afs_partitions
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	x8, [x0]
	cmp	x8, #1
	b.lt	LBB0_18
; %bb.1:
	mov	x19, x1
	mov	x20, x0
	mov	w23, #0
	mov	x22, #0
	mov	x21, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x21
	bl	_afs_is_v1
	add	x8, x22, #8
	cmp	x0, #0
	csel	x22, x22, x8, eq
	cinc	w23, w23, ne
	mov	x0, x20
	mov	x1, x21
	bl	_afs_is_v2
	add	x8, x22, #8
	cmp	x0, #0
	csel	x22, x22, x8, eq
	cinc	w23, w23, ne
	ldp	x9, x8, [x20]
	add	x21, x8, x21
	cmp	x21, x9
	b.lt	LBB0_2
; %bb.3:
	cbz	w23, LBB0_22
; %bb.4:
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x22
	bl	_kzalloc
	cbz	x0, LBB0_19
; %bb.5:
	mov	x21, x0
	ldr	x8, [x20]
	cmp	x8, #1
	b.lt	LBB0_20
; %bb.6:
	mov	w24, #0
	mov	x22, #0
	b	LBB0_9
LBB0_7:                                 ;   in Loop: Header=BB0_9 Depth=1
	add	w24, w24, #1
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	ldp	x9, x8, [x20]
	add	x22, x8, x22
	cmp	x22, x9
	b.ge	LBB0_21
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x22
	bl	_afs_is_v1
	cbz	x0, LBB0_12
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	add	x2, x21, w24, sxtw #3
	mov	x0, x20
	mov	x1, x22
	bl	_afs_parse_v1_partition
	cbnz	w0, LBB0_14
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	add	w24, w24, #1
LBB0_12:                                ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x20
	mov	x1, x22
	bl	_afs_is_v2
	cbz	x0, LBB0_8
; %bb.13:                               ;   in Loop: Header=BB0_9 Depth=1
	add	x2, x21, w24, sxtw #3
	mov	x0, x20
	mov	x1, x22
	bl	_afs_parse_v2_partition
	cbz	w0, LBB0_7
LBB0_14:
	mov	x23, x0
	tbnz	w24, #31, LBB0_17
; %bb.15:
	mov	w8, w24
	lsl	x20, x8, #3
LBB0_16:                                ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x21, x20]
	bl	_kfree
	sub	x20, x20, #8
	cmn	x20, #8
	b.ne	LBB0_16
LBB0_17:
	mov	x0, x21
	bl	_kfree
	str	xzr, [x19]
	b	LBB0_22
LBB0_18:
	mov	w23, #0
	b	LBB0_22
LBB0_19:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w23, w8
	b	LBB0_22
LBB0_20:
	mov	w24, #0
LBB0_21:
	str	x21, [x19]
	mov	x23, x24
LBB0_22:
	mov	x0, x23
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_parse_afs_partitions
.subsections_via_symbols
