	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cp_refill_rx
_cp_refill_rx:                          ## @cp_refill_rx
	.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	_CP_RX_RING_SIZE@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_10
## %bb.1:
	movq	%rdi, %r15
	movq	32(%rdi), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	xorl	%r13d, %r13d
	xorl	%r14d, %r14d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r15), %eax
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	orl	%eax, %edi
	callq	_cpu_to_le32
	movq	8(%r15), %rcx
	movq	%rax, (%rcx,%r13)
	incq	%r14
	movl	(%rbx), %eax
	addq	$24, %r13
	cmpq	%rax, %r14
	jae	LBB0_10
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r15), %esi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_netdev_alloc_skb_ip_align
	testq	%rax, %rax
	je	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, %r12
	movq	24(%r15), %rdi
	movl	(%rax), %esi
	movl	(%r15), %edx
	movq	_PCI_DMA_FROMDEVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	callq	_dma_map_single
	movl	%eax, %ebx
	movq	24(%r15), %rdi
	movl	%eax, %esi
	callq	_dma_mapping_error
	testq	%rax, %rax
	jne	LBB0_4
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	16(%r15), %rax
	movq	%r12, (%rax,%r14,8)
	movq	8(%r15), %rax
	movq	$0, 16(%rax,%r13)
	movl	%ebx, %edi
	callq	_cpu_to_le64
	movq	8(%r15), %rcx
	movl	%eax, 8(%rcx,%r13)
	movq	_CP_RX_RING_SIZE@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	decl	%eax
	movq	_DescOwn@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	cmpq	%rax, %r14
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%edi, %eax
	movq	_RingEnd@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%r15), %edi
	jmp	LBB0_9
LBB0_10:
	xorl	%eax, %eax
	jmp	LBB0_11
LBB0_4:
	movq	%r12, %rdi
	callq	_kfree_skb
LBB0_5:
	movq	%r15, %rdi
	callq	_cp_clean_rings
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CP_RX_RING_SIZE,4,2            ## @CP_RX_RING_SIZE
	.comm	_PCI_DMA_FROMDEVICE,4,2         ## @PCI_DMA_FROMDEVICE
	.comm	_DescOwn,4,2                    ## @DescOwn
	.comm	_RingEnd,4,2                    ## @RingEnd
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_cp_refill_rx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cp_refill_rx
_cp_refill_rx:                          ; @cp_refill_rx
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
Lloh0:
	adrp	x23, _CP_RX_RING_SIZE@GOTPAGE
Lloh1:
	ldr	x23, [x23, _CP_RX_RING_SIZE@GOTPAGEOFF]
	ldr	w8, [x23]
	cbz	w8, LBB0_8
; %bb.1:
	mov	x19, x0
	mov	x24, #0
	mov	x25, #0
	ldr	x20, [x0, #32]
Lloh2:
	adrp	x26, _PCI_DMA_FROMDEVICE@GOTPAGE
Lloh3:
	ldr	x26, [x26, _PCI_DMA_FROMDEVICE@GOTPAGEOFF]
Lloh4:
	adrp	x27, _DescOwn@GOTPAGE
Lloh5:
	ldr	x27, [x27, _DescOwn@GOTPAGEOFF]
Lloh6:
	adrp	x28, _RingEnd@GOTPAGE
Lloh7:
	ldr	x28, [x28, _RingEnd@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w9, [x19]
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	orr	w0, w9, w8
	bl	_cpu_to_le32
	ldr	x8, [x19, #8]
	str	x0, [x8, x24]
	add	x25, x25, #1
	ldr	w8, [x23]
	add	x24, x24, #24
	cmp	x25, x8
	b.hs	LBB0_8
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x19]
	mov	x0, x20
	bl	_netdev_alloc_skb_ip_align
	cbz	x0, LBB0_10
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x21, x0
	ldr	x0, [x19, #24]
	ldr	w1, [x21]
	ldr	w2, [x19]
	ldr	w3, [x26]
	bl	_dma_map_single
	mov	x22, x0
	ldr	x0, [x19, #24]
	mov	x1, x22
	bl	_dma_mapping_error
	cbnz	x0, LBB0_9
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x19, #16]
	str	x21, [x8, x25, lsl #3]
	ldr	x8, [x19, #8]
	add	x8, x8, x24
	str	xzr, [x8, #16]
	mov	x0, x22
	bl	_cpu_to_le64
	ldr	x8, [x19, #8]
	add	x8, x8, x24
	str	w0, [x8, #8]
	ldr	w8, [x23]
	sub	w9, w8, #1
	ldr	w8, [x27]
	cmp	x25, x9
	b.ne	LBB0_2
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w9, [x28]
	orr	w9, w9, w8
	ldr	w8, [x19]
	b	LBB0_3
LBB0_8:
	mov	w0, #0
	b	LBB0_11
LBB0_9:
	mov	x0, x21
	bl	_kfree_skb
LBB0_10:
	mov	x0, x19
	bl	_cp_clean_rings
Lloh8:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_11:
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_CP_RX_RING_SIZE,4,2            ; @CP_RX_RING_SIZE
	.comm	_PCI_DMA_FROMDEVICE,4,2         ; @PCI_DMA_FROMDEVICE
	.comm	_DescOwn,4,2                    ; @DescOwn
	.comm	_RingEnd,4,2                    ; @RingEnd
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_cp_refill_rx
.subsections_via_symbols
