	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ucan_alloc_context_array
_ucan_alloc_context_array:              ## @ucan_alloc_context_array
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	callq	_ucan_release_context_array
	movl	4(%rbx), %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$16, %esi
	callq	_kcalloc
	movq	%rax, 8(%rbx)
	testq	%rax, %rax
	je	LBB0_4
## %bb.1:
	movl	4(%rbx), %ecx
	testl	%ecx, %ecx
	jle	LBB0_9
## %bb.2:
	cmpl	$1, %ecx
	jne	LBB0_5
## %bb.3:
	xorl	%edx, %edx
	jmp	LBB0_7
LBB0_4:
	movl	16(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	callq	_netdev_err
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_10
LBB0_5:
	movl	%ecx, %esi
	andl	$-2, %esi
	leaq	24(%rax), %rdi
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movl	$0, -24(%rdi)
	movq	%rbx, -16(%rdi)
	movl	$0, -8(%rdi)
	movq	%rbx, (%rdi)
	addq	$2, %rdx
	addq	$32, %rdi
	cmpq	%rdx, %rsi
	jne	LBB0_6
LBB0_7:
	testb	$1, %cl
	je	LBB0_9
## %bb.8:
	shlq	$4, %rdx
	movl	$0, (%rax,%rdx)
	movq	%rbx, 8(%rax,%rdx)
LBB0_9:
	movl	%ecx, (%rbx)
	xorl	%eax, %eax
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Not enough memory to allocate tx contexts\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_ucan_alloc_context_array
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ucan_alloc_context_array
_ucan_alloc_context_array:              ; @ucan_alloc_context_array
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	bl	_ucan_release_context_array
	ldr	w0, [x19, #4]
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	w1, #16
	bl	_kcalloc
	str	x0, [x19, #8]
	cbz	x0, LBB0_4
; %bb.1:
	ldr	w8, [x19, #4]
	cmp	w8, #1
	b.lt	LBB0_10
; %bb.2:
	cmp	w8, #4
	b.hs	LBB0_5
; %bb.3:
	mov	x9, #0
	b	LBB0_8
LBB0_4:
	ldr	w0, [x19, #16]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_netdev_err
Lloh5:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_11
LBB0_5:
	and	x9, x8, #0xfffffffc
	add	x10, x0, #32
	mov	x11, x9
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	stur	wzr, [x10, #-32]
	stur	wzr, [x10, #-16]
	str	wzr, [x10]
	str	wzr, [x10, #16]
	stur	x19, [x10, #-24]
	stur	x19, [x10, #-8]
	str	x19, [x10, #8]
	str	x19, [x10, #24]
	add	x10, x10, #64
	subs	x11, x11, #4
	b.ne	LBB0_6
; %bb.7:
	cmp	x9, x8
	b.eq	LBB0_10
LBB0_8:
	add	x10, x0, x9, lsl #4
	add	x10, x10, #8
	sub	x9, x8, x9
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	stur	wzr, [x10, #-8]
	str	x19, [x10], #16
	subs	x9, x9, #1
	b.ne	LBB0_9
LBB0_10:
	mov	w0, #0
	str	w8, [x19]
LBB0_11:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Not enough memory to allocate tx contexts\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_ucan_alloc_context_array
.subsections_via_symbols
