	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function init_ring
_init_ring:                             ## @init_ring
	.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, %rbx
	callq	_netdev_priv
	movq	%rax, %r15
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%rax)
	movups	%xmm0, 80(%rax)
	movq	$0, 96(%rax)
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %esi
	cmpl	$1501, %esi                     ## imm = 0x5DD
	jge	LBB0_1
## %bb.2:
	movq	_PKT_BUF_SZ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	jmp	LBB0_3
LBB0_1:
	addl	$32, %esi
LBB0_3:
	movl	%esi, 16(%r15)
	movq	_RX_RING_SIZE@GOTPCREL(%rip), %r14
	xorl	%r12d, %r12d
	cmpl	$0, (%r14)
	jle	LBB0_12
## %bb.4:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_netdev_alloc_skb
	movq	%rax, %rbx
	movq	56(%r15), %rax
	movq	%rbx, 8(%rax)
	testq	%rbx, %rbx
	je	LBB0_12
## %bb.5:
	xorl	%r14d, %r14d
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r13, %r12
	movl	16(%r15), %edx
	movl	72(%r15), %edi
	movl	(%rbx), %esi
	movq	_PCI_DMA_FROMDEVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	callq	_pci_map_single
	movq	56(%r15), %rcx
	movl	%eax, (%rcx,%r14,2)
	movl	72(%r15), %edi
	movl	%eax, %esi
	callq	_pci_dma_mapping_error
	testq	%rax, %rax
	jne	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	56(%r15), %rax
	movq	_RxDescValid@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	orl	(%rax,%r14,2), %edi
	callq	_cpu_to_dma
	movq	48(%r15), %rcx
	movq	%rax, (%rcx,%r14)
	leaq	1(%r12), %r13
	movq	_RX_RING_SIZE@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	cmpq	%rax, %r13
	jge	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_6 Depth=1
	movl	16(%r15), %esi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_netdev_alloc_skb
	movq	%rax, %rbx
	movq	56(%r15), %rax
	movq	%rbx, 24(%rax,%r14,2)
	addq	$8, %r14
	testq	%rbx, %rbx
	jne	LBB0_6
LBB0_10:
	incl	%r12d
	jmp	LBB0_11
LBB0_7:
	movq	%rbx, %rdi
	callq	_dev_kfree_skb
	movq	56(%r15), %rax
	movq	$0, 8(%rax,%r14,2)
LBB0_11:
	movq	_RX_RING_SIZE@GOTPCREL(%rip), %r14
LBB0_12:
	leal	-1(%r12), %edi
	movq	_RxDescQIdx@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	64(%r15), %rsi
	callq	_writew
	movl	%r12d, %eax
	subl	(%r14), %eax
	movl	%eax, (%r15)
	cmpl	(%r14), %r12d
	jge	LBB0_15
## %bb.13:
	movq	48(%r15), %rax
	movq	56(%r15), %rdx
	movl	%r12d, %ecx
	movq	%rcx, %rsi
	shlq	$4, %rsi
	addq	%rsi, %rdx
	addq	$8, %rdx
	.p2align	4, 0x90
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	movq	$0, (%rax,%rcx,8)
	movq	$0, (%rdx)
	movl	$0, -8(%rdx)
	incq	%rcx
	addq	$16, %rdx
	cmpl	%ecx, (%r14)
	jg	LBB0_14
LBB0_15:
	movq	_RxDescEndRing@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_dma
	movq	48(%r15), %rcx
	movslq	(%r14), %rdx
	orq	%rax, -8(%rcx,%rdx,8)
	movq	_DONE_Q_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	testl	%r9d, %r9d
	jle	LBB0_27
## %bb.16:
	movq	32(%r15), %rcx
	movq	40(%r15), %rdx
	cmpl	$4, %r9d
	jae	LBB0_19
## %bb.17:
	xorl	%esi, %esi
	jmp	LBB0_18
LBB0_19:
	movl	%r9d, %esi
	andl	$-4, %esi
	leaq	-4(%rsi), %rax
	movq	%rax, %rdi
	shrq	$2, %rdi
	incq	%rdi
	movl	%edi, %r8d
	andl	$3, %r8d
	cmpq	$12, %rax
	jae	LBB0_21
## %bb.20:
	xorl	%ebx, %ebx
	jmp	LBB0_23
LBB0_21:
	andq	$-4, %rdi
	xorl	%ebx, %ebx
	xorps	%xmm0, %xmm0
	.p2align	4, 0x90
LBB0_22:                                ## =>This Inner Loop Header: Depth=1
	movups	%xmm0, (%rdx,%rbx,8)
	movups	%xmm0, 16(%rdx,%rbx,8)
	movups	%xmm0, (%rcx,%rbx,8)
	movups	%xmm0, 16(%rcx,%rbx,8)
	movups	%xmm0, 32(%rdx,%rbx,8)
	movups	%xmm0, 48(%rdx,%rbx,8)
	movups	%xmm0, 32(%rcx,%rbx,8)
	movups	%xmm0, 48(%rcx,%rbx,8)
	movups	%xmm0, 64(%rdx,%rbx,8)
	movups	%xmm0, 80(%rdx,%rbx,8)
	movups	%xmm0, 64(%rcx,%rbx,8)
	movups	%xmm0, 80(%rcx,%rbx,8)
	movups	%xmm0, 96(%rdx,%rbx,8)
	movups	%xmm0, 112(%rdx,%rbx,8)
	movups	%xmm0, 96(%rcx,%rbx,8)
	movups	%xmm0, 112(%rcx,%rbx,8)
	addq	$16, %rbx
	addq	$-4, %rdi
	jne	LBB0_22
LBB0_23:
	testq	%r8, %r8
	je	LBB0_26
## %bb.24:
	leaq	(%rcx,%rbx,8), %rdi
	addq	$16, %rdi
	leaq	(%rdx,%rbx,8), %rbx
	addq	$16, %rbx
	shlq	$5, %r8
	xorl	%eax, %eax
	xorps	%xmm0, %xmm0
	.p2align	4, 0x90
LBB0_25:                                ## =>This Inner Loop Header: Depth=1
	movups	%xmm0, -16(%rbx,%rax)
	movups	%xmm0, (%rbx,%rax)
	movups	%xmm0, -16(%rdi,%rax)
	movups	%xmm0, (%rdi,%rax)
	addq	$32, %rax
	cmpq	%rax, %r8
	jne	LBB0_25
LBB0_26:
	cmpq	%r9, %rsi
	je	LBB0_27
	.p2align	4, 0x90
LBB0_18:                                ## =>This Inner Loop Header: Depth=1
	movq	$0, (%rdx,%rsi,8)
	movq	$0, (%rcx,%rsi,8)
	incq	%rsi
	cmpq	%rsi, %r9
	jne	LBB0_18
LBB0_27:
	movq	_TX_RING_SIZE@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	jle	LBB0_30
## %bb.28:
	xorl	%r12d, %r12d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_29:                                ## =>This Inner Loop Header: Depth=1
	movq	24(%r15), %rdi
	addq	%r12, %rdi
	xorl	%esi, %esi
	movl	$4, %edx
	callq	_memset
	incq	%rbx
	movslq	(%r14), %rax
	addq	$4, %r12
	cmpq	%rax, %rbx
	jl	LBB0_29
LBB0_30:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PKT_BUF_SZ,4,2                 ## @PKT_BUF_SZ
	.comm	_RX_RING_SIZE,4,2               ## @RX_RING_SIZE
	.comm	_PCI_DMA_FROMDEVICE,4,2         ## @PCI_DMA_FROMDEVICE
	.comm	_RxDescValid,4,2                ## @RxDescValid
	.comm	_RxDescQIdx,8,3                 ## @RxDescQIdx
	.comm	_RxDescEndRing,4,2              ## @RxDescEndRing
	.comm	_DONE_Q_SIZE,4,2                ## @DONE_Q_SIZE
	.comm	_TX_RING_SIZE,4,2               ## @TX_RING_SIZE
	.no_dead_strip	_init_ring
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function init_ring
_init_ring:                             ; @init_ring
	.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
	mov	x20, x0
	bl	_netdev_priv
	mov	x19, x0
	stp	xzr, xzr, [x0]
	stp	xzr, xzr, [x0, #88]
	str	xzr, [x0, #80]
	ldr	w8, [x20]
Lloh0:
	adrp	x9, _PKT_BUF_SZ@GOTPAGE
Lloh1:
	ldr	x9, [x9, _PKT_BUF_SZ@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	add	w10, w8, #32
	cmp	w8, #1501
	csel	w1, w9, w10, lt
	str	w1, [x0, #16]
Lloh3:
	adrp	x22, _RX_RING_SIZE@GOTPAGE
Lloh4:
	ldr	x22, [x22, _RX_RING_SIZE@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_7
; %bb.1:
	mov	x0, x20
	bl	_netdev_alloc_skb
	ldr	x8, [x19, #56]
	str	x0, [x8, #8]
	cbz	x0, LBB0_7
; %bb.2:
	mov	x21, x0
	mov	x24, #0
	mov	x27, #0
Lloh5:
	adrp	x25, _PCI_DMA_FROMDEVICE@GOTPAGE
Lloh6:
	ldr	x25, [x25, _PCI_DMA_FROMDEVICE@GOTPAGEOFF]
Lloh7:
	adrp	x26, _RxDescValid@GOTPAGE
Lloh8:
	ldr	x26, [x26, _RxDescValid@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x23, x27
	ldr	w0, [x19, #72]
	ldr	w1, [x21]
	ldr	w2, [x19, #16]
	ldr	w3, [x25]
	bl	_pci_map_single
	mov	x1, x0
	ldr	x8, [x19, #56]
	str	w0, [x8, x24]
	ldr	w0, [x19, #72]
	bl	_pci_dma_mapping_error
	cbnz	x0, LBB0_23
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x19, #56]
	ldr	w8, [x8, x24]
	ldr	w9, [x26]
	orr	w0, w9, w8
	bl	_cpu_to_dma
	ldr	x8, [x19, #48]
	str	x0, [x8, x23, lsl #3]
	add	x27, x23, #1
	ldrsw	x8, [x22]
	cmp	x27, x8
	b.ge	LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w1, [x19, #16]
	mov	x0, x20
	bl	_netdev_alloc_skb
	mov	x21, x0
	ldr	x8, [x19, #56]
	add	x8, x8, x24
	str	x0, [x8, #24]
	add	x24, x24, #16
	cbnz	x0, LBB0_3
LBB0_6:
	add	w23, w23, #1
	b	LBB0_8
LBB0_7:
	mov	w23, #0
LBB0_8:
	sub	w0, w23, #1
	ldr	x8, [x19, #64]
Lloh9:
	adrp	x9, _RxDescQIdx@GOTPAGE
Lloh10:
	ldr	x9, [x9, _RxDescQIdx@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_writew
	ldr	w8, [x22]
	sub	w8, w23, w8
	str	w8, [x19]
	ldr	w8, [x22]
	cmp	w23, w8
	b.ge	LBB0_11
; %bb.9:
	ldp	x8, x10, [x19, #48]
	mov	w9, w23
	add	x10, x10, w23, uxtw #4
	add	x10, x10, #8
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	str	xzr, [x8, x9, lsl #3]
	str	xzr, [x10]
	stur	wzr, [x10, #-8]
	add	x9, x9, #1
	ldr	w11, [x22]
	add	x10, x10, #16
	cmp	w11, w9
	b.gt	LBB0_10
LBB0_11:
Lloh12:
	adrp	x8, _RxDescEndRing@GOTPAGE
Lloh13:
	ldr	x8, [x8, _RxDescEndRing@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	bl	_cpu_to_dma
	ldr	x8, [x19, #48]
	ldrsw	x9, [x22]
	add	x8, x8, x9, lsl #3
	ldur	x9, [x8, #-8]
	orr	x9, x9, x0
	stur	x9, [x8, #-8]
Lloh15:
	adrp	x8, _DONE_Q_SIZE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _DONE_Q_SIZE@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	cmp	w8, #1
	b.lt	LBB0_19
; %bb.12:
	ldp	x9, x10, [x19, #32]
	cmp	w8, #8
	b.hs	LBB0_14
; %bb.13:
	mov	x11, #0
	b	LBB0_17
LBB0_14:
	and	x11, x8, #0xfffffff8
	add	x12, x9, #32
	add	x13, x10, #32
	movi.2d	v0, #0000000000000000
	mov	x14, x11
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	stp	q0, q0, [x13, #-32]
	stp	q0, q0, [x12, #-32]
	stp	q0, q0, [x12], #64
	stp	q0, q0, [x13], #64
	subs	x14, x14, #8
	b.ne	LBB0_15
; %bb.16:
	cmp	x11, x8
	b.eq	LBB0_19
LBB0_17:
	lsl	x12, x11, #3
	add	x10, x10, x12
	add	x9, x9, x12
	sub	x8, x8, x11
LBB0_18:                                ; =>This Inner Loop Header: Depth=1
	str	xzr, [x10], #8
	str	xzr, [x9], #8
	subs	x8, x8, #1
	b.ne	LBB0_18
LBB0_19:
Lloh18:
	adrp	x20, _TX_RING_SIZE@GOTPAGE
Lloh19:
	ldr	x20, [x20, _TX_RING_SIZE@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_22
; %bb.20:
	mov	x21, #0
	mov	x22, #0
LBB0_21:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #24]
	add	x0, x8, x21
	mov	w1, #0
	mov	w2, #4
	bl	_memset
	add	x22, x22, #1
	ldrsw	x8, [x20]
	add	x21, x21, #4
	cmp	x22, x8
	b.lt	LBB0_21
LBB0_22:
	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
LBB0_23:
	mov	x0, x21
	bl	_dev_kfree_skb
	ldr	x8, [x19, #56]
	add	x8, x8, x24
	str	xzr, [x8, #8]
	b	LBB0_8
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_PKT_BUF_SZ,4,2                 ; @PKT_BUF_SZ
	.comm	_RX_RING_SIZE,4,2               ; @RX_RING_SIZE
	.comm	_PCI_DMA_FROMDEVICE,4,2         ; @PCI_DMA_FROMDEVICE
	.comm	_RxDescValid,4,2                ; @RxDescValid
	.comm	_RxDescQIdx,8,3                 ; @RxDescQIdx
	.comm	_RxDescEndRing,4,2              ; @RxDescEndRing
	.comm	_DONE_Q_SIZE,4,2                ; @DONE_Q_SIZE
	.comm	_TX_RING_SIZE,4,2               ; @TX_RING_SIZE
	.no_dead_strip	_init_ring
.subsections_via_symbols
