	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fec_enet_alloc_queue
_fec_enet_alloc_queue:                  ## @fec_enet_alloc_queue
	.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	%rdi, -48(%rbp)                 ## 8-byte Spill
	callq	_netdev_priv
	movq	%rax, %r15
	cmpl	$0, (%rax)
	jle	LBB0_5
## %bb.1:
	xorl	%r12d, %r12d
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r13
	movq	_TSO_HEADER_SIZE@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %esi
	movl	$20, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_10
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, %rbx
	movq	32(%r15), %rax
	movq	%rbx, (%rax,%r12,8)
	movq	_TX_RING_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%esi, 16(%rbx)
	movq	32(%r15), %rax
	movq	(%rax,%r12,8), %rax
	movl	16(%rax), %eax
	addl	%eax, 40(%r15)
	movq	_FEC_MAX_SKB_DESCS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%rbx)
	movl	%esi, %ecx
	subl	%eax, %ecx
	movl	%ecx, %eax
	shrl	$31, %eax
	addl	%ecx, %eax
	sarl	%eax
	movl	%eax, 4(%rbx)
	movq	24(%r15), %rdi
	imull	(%r14), %esi
	movq	%rbx, %rdx
	addq	$12, %rdx
	movl	(%r13), %ecx
	callq	_dma_alloc_coherent
	movl	%eax, 8(%rbx)
	testl	%eax, %eax
	je	LBB0_10
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	incq	%r12
	movslq	(%r15), %rax
	cmpq	%rax, %r12
	jl	LBB0_2
LBB0_5:
	cmpl	$0, 4(%r15)
	jle	LBB0_11
## %bb.6:
	xorl	%ebx, %ebx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r14
	movq	_RX_RING_SIZE@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %esi
	movl	$8, %edi
	callq	_kzalloc
	movq	8(%r15), %rcx
	movq	%rax, (%rcx,%rbx,8)
	movq	8(%r15), %rax
	movq	(%rax,%rbx,8), %rax
	testq	%rax, %rax
	je	LBB0_10
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	(%r12), %rcx
	movq	%rcx, (%rax)
	addl	%ecx, 16(%r15)
	incq	%rbx
	movslq	4(%r15), %rax
	cmpq	%rax, %rbx
	jl	LBB0_7
LBB0_11:
	xorl	%ebx, %ebx
	jmp	LBB0_12
LBB0_10:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_fec_enet_free_queue
LBB0_12:
	movl	%ebx, %eax
	addq	$8, %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
	.comm	_TX_RING_SIZE,4,2               ## @TX_RING_SIZE
	.comm	_FEC_MAX_SKB_DESCS,4,2          ## @FEC_MAX_SKB_DESCS
	.comm	_TSO_HEADER_SIZE,4,2            ## @TSO_HEADER_SIZE
	.comm	_RX_RING_SIZE,8,3               ## @RX_RING_SIZE
	.no_dead_strip	_fec_enet_alloc_queue
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fec_enet_alloc_queue
_fec_enet_alloc_queue:                  ; @fec_enet_alloc_queue
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x0
	bl	_netdev_priv
	mov	x20, x0
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.1:
	mov	x22, #0
Lloh0:
	adrp	x23, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x23, [x23, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	adrp	x24, _TX_RING_SIZE@GOTPAGE
Lloh3:
	ldr	x24, [x24, _TX_RING_SIZE@GOTPAGEOFF]
Lloh4:
	adrp	x25, _FEC_MAX_SKB_DESCS@GOTPAGE
Lloh5:
	ldr	x25, [x25, _FEC_MAX_SKB_DESCS@GOTPAGEOFF]
Lloh6:
	adrp	x26, _TSO_HEADER_SIZE@GOTPAGE
Lloh7:
	ldr	x26, [x26, _TSO_HEADER_SIZE@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x23]
	mov	w0, #20
	bl	_kzalloc
	cbz	x0, LBB0_10
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x21, x0
	ldr	x8, [x20, #32]
	lsl	x9, x22, #3
	str	x0, [x8, x9]
	ldr	w8, [x24]
	str	w8, [x0, #16]
	ldp	x0, x10, [x20, #24]
	ldr	x9, [x10, x9]
	ldr	w9, [x9, #16]
	ldr	w10, [x20, #40]
	add	w9, w10, w9
	str	w9, [x20, #40]
	ldr	w9, [x25]
	sub	w10, w8, w9
	cmp	w10, #0
	cinc	w10, w10, lt
	asr	w10, w10, #1
	stp	w9, w10, [x21]
	ldr	w9, [x26]
	mul	w1, w9, w8
	add	x2, x21, #12
	ldr	w3, [x23]
	bl	_dma_alloc_coherent
	str	w0, [x21, #8]
	cbz	w0, LBB0_10
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	add	x22, x22, #1
	ldrsw	x8, [x20]
	cmp	x22, x8
	b.lt	LBB0_2
LBB0_5:
	ldr	w8, [x20, #4]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.6:
	mov	x21, #0
Lloh8:
	adrp	x22, _GFP_KERNEL@GOTPAGE
Lloh9:
	ldr	x22, [x22, _GFP_KERNEL@GOTPAGEOFF]
Lloh10:
	adrp	x23, _RX_RING_SIZE@GOTPAGE
Lloh11:
	ldr	x23, [x23, _RX_RING_SIZE@GOTPAGEOFF]
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x22]
	mov	w0, #8
	bl	_kzalloc
	ldr	x8, [x20, #8]
	lsl	x9, x21, #3
	str	x0, [x8, x9]
	ldr	x8, [x20, #8]
	ldr	x8, [x8, x9]
	cbz	x8, LBB0_10
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x9, [x23]
	str	x9, [x8]
	ldr	w8, [x20, #16]
	add	w8, w8, w9
	str	w8, [x20, #16]
	add	x21, x21, #1
	ldrsw	x8, [x20, #4]
	cmp	x21, x8
	b.lt	LBB0_7
LBB0_9:
	mov	w20, #0
	b	LBB0_11
LBB0_10:
Lloh12:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w20, w8
	mov	x0, x19
	bl	_fec_enet_free_queue
LBB0_11:
	mov	x0, x20
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_TX_RING_SIZE,4,2               ; @TX_RING_SIZE
	.comm	_FEC_MAX_SKB_DESCS,4,2          ; @FEC_MAX_SKB_DESCS
	.comm	_TSO_HEADER_SIZE,4,2            ; @TSO_HEADER_SIZE
	.comm	_RX_RING_SIZE,8,3               ; @RX_RING_SIZE
	.no_dead_strip	_fec_enet_alloc_queue
.subsections_via_symbols
