	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bcmgenet_init_rx_ring
_bcmgenet_init_rx_ring:                 ## @bcmgenet_init_rx_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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
                                        ## kill: def $r8d killed $r8d def $r8
	movq	%r8, -72(%rbp)                  ## 8-byte Spill
	movl	%ecx, %r15d
	movl	%edx, -60(%rbp)                 ## 4-byte Spill
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movq	16(%rdi), %r13
	movl	%esi, %eax
	imulq	$56, %rax, %r12
	leaq	(%r12,%r13), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	callq	_WORDS_PER_BD
	movq	%rbx, 48(%r13,%r12)
	movl	%r14d, (%r13,%r12)
	movq	_DESC_INDEX@GOTPCREL(%rip), %rcx
	movl	%r14d, -52(%rbp)                ## 4-byte Spill
	cmpl	%r14d, (%rcx)
	movq	_bcmgenet_rx_ring_int_enable@GOTPCREL(%rip), %rcx
	cmoveq	_bcmgenet_rx_ring16_int_enable@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 44(%r13,%r12)
	movq	_bcmgenet_rx_ring_int_disable@GOTPCREL(%rip), %rcx
	cmoveq	_bcmgenet_rx_ring16_int_disable@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 40(%r13,%r12)
	movl	%r15d, %ecx
	addq	8(%rbx), %rcx
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	%rcx, 32(%r13,%r12)
	movl	-60(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, %r14d
	movl	%eax, 4(%r13,%r12)
	movq	%rbx, %rdi
	movq	$0, 24(%r13,%r12)
	movl	%r15d, 8(%r13,%r12)
	movl	%r15d, -56(%rbp)                ## 4-byte Spill
	movl	%r15d, 12(%r13,%r12)
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	decl	%eax
	movl	%eax, 16(%r13,%r12)
	movq	%rdi, %r15
	movq	%rbx, %rsi
	callq	_bcmgenet_alloc_rx_buffers
	testl	%eax, %eax
	jne	LBB0_2
## %bb.1:
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_bcmgenet_dim_work@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_bcmgenet_init_dim
	movq	%rbx, %rdi
	callq	_bcmgenet_init_rx_coalesce
	movq	%r15, %rbx
	movl	(%r15), %edi
	leaq	(%r12,%r13), %rsi
	addq	$20, %rsi
	movq	_bcmgenet_rx_poll@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_NAPI_POLL_WEIGHT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	callq	_netif_napi_add
	movq	_RDMA_PROD_INDEX@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r15, %rdi
	movl	-52(%rbp), %r15d                ## 4-byte Reload
	movl	%r15d, %esi
	xorl	%edx, %edx
	callq	_bcmgenet_rdma_ring_writel
	movq	_RDMA_CONS_INDEX@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	xorl	%edx, %edx
	callq	_bcmgenet_rdma_ring_writel
	movq	_DMA_RING_SIZE_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %r14d
	movq	_RX_BUF_LENGTH@GOTPCREL(%rip), %rax
	orl	(%rax), %r14d
	movq	_DMA_RING_BUF_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	callq	_bcmgenet_rdma_ring_writel
	movq	_DMA_FC_THRESH_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_DMA_XOFF_THRESHOLD_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %edx
	movq	_DMA_FC_THRESH_HI@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	_RDMA_XON_XOFF_THRESH@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_bcmgenet_rdma_ring_writel
	movl	-48(%rbp), %r12d                ## 4-byte Reload
	movl	-56(%rbp), %r14d                ## 4-byte Reload
	imull	%r12d, %r14d
	movq	_DMA_START_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	callq	_bcmgenet_rdma_ring_writel
	movq	_RDMA_READ_PTR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	callq	_bcmgenet_rdma_ring_writel
	movq	_RDMA_WRITE_PTR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	callq	_bcmgenet_rdma_ring_writel
	movq	-72(%rbp), %rdx                 ## 8-byte Reload
	imull	%r12d, %edx
	decl	%edx
	movq	_DMA_END_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rdi
	movl	%r15d, %esi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_bcmgenet_rdma_ring_writel
	movl	-44(%rbp), %eax                 ## 4-byte Reload
LBB0_2:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DESC_INDEX,4,2                 ## @DESC_INDEX
	.comm	_bcmgenet_rx_ring16_int_enable,4,2 ## @bcmgenet_rx_ring16_int_enable
	.comm	_bcmgenet_rx_ring16_int_disable,4,2 ## @bcmgenet_rx_ring16_int_disable
	.comm	_bcmgenet_rx_ring_int_enable,4,2 ## @bcmgenet_rx_ring_int_enable
	.comm	_bcmgenet_rx_ring_int_disable,4,2 ## @bcmgenet_rx_ring_int_disable
	.comm	_bcmgenet_dim_work,4,2          ## @bcmgenet_dim_work
	.comm	_bcmgenet_rx_poll,4,2           ## @bcmgenet_rx_poll
	.comm	_NAPI_POLL_WEIGHT,4,2           ## @NAPI_POLL_WEIGHT
	.comm	_RDMA_PROD_INDEX,4,2            ## @RDMA_PROD_INDEX
	.comm	_RDMA_CONS_INDEX,4,2            ## @RDMA_CONS_INDEX
	.comm	_DMA_RING_SIZE_SHIFT,4,2        ## @DMA_RING_SIZE_SHIFT
	.comm	_RX_BUF_LENGTH,4,2              ## @RX_BUF_LENGTH
	.comm	_DMA_RING_BUF_SIZE,4,2          ## @DMA_RING_BUF_SIZE
	.comm	_DMA_FC_THRESH_LO,4,2           ## @DMA_FC_THRESH_LO
	.comm	_DMA_XOFF_THRESHOLD_SHIFT,4,2   ## @DMA_XOFF_THRESHOLD_SHIFT
	.comm	_DMA_FC_THRESH_HI,4,2           ## @DMA_FC_THRESH_HI
	.comm	_RDMA_XON_XOFF_THRESH,4,2       ## @RDMA_XON_XOFF_THRESH
	.comm	_DMA_START_ADDR,4,2             ## @DMA_START_ADDR
	.comm	_RDMA_READ_PTR,4,2              ## @RDMA_READ_PTR
	.comm	_RDMA_WRITE_PTR,4,2             ## @RDMA_WRITE_PTR
	.comm	_DMA_END_ADDR,4,2               ## @DMA_END_ADDR
	.no_dead_strip	_bcmgenet_init_rx_ring
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bcmgenet_init_rx_ring
_bcmgenet_init_rx_ring:                 ; @bcmgenet_init_rx_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	x21, x4
	mov	x23, x3
	mov	x25, x2
	mov	x19, x1
	mov	x20, x0
	ldr	x27, [x0, #16]
	mov	w8, #56
	umaddl	x26, w1, w8, x27
	bl	_WORDS_PER_BD
	mov	x22, x0
	str	x20, [x26, #48]
	str	w19, [x26]
Lloh0:
	adrp	x8, _DESC_INDEX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DESC_INDEX@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _bcmgenet_rx_ring16_int_enable@GOTPAGE
Lloh4:
	ldr	x9, [x9, _bcmgenet_rx_ring16_int_enable@GOTPAGEOFF]
Lloh5:
	adrp	x10, _bcmgenet_rx_ring_int_enable@GOTPAGE
Lloh6:
	ldr	x10, [x10, _bcmgenet_rx_ring_int_enable@GOTPAGEOFF]
	cmp	w8, w19
	csel	x8, x9, x10, eq
	ldr	w8, [x8]
	str	w8, [x26, #44]
Lloh7:
	adrp	x8, _bcmgenet_rx_ring16_int_disable@GOTPAGE
Lloh8:
	ldr	x8, [x8, _bcmgenet_rx_ring16_int_disable@GOTPAGEOFF]
Lloh9:
	adrp	x9, _bcmgenet_rx_ring_int_disable@GOTPAGE
Lloh10:
	ldr	x9, [x9, _bcmgenet_rx_ring_int_disable@GOTPAGEOFF]
	csel	x8, x8, x9, eq
	ldr	w8, [x8]
	str	w8, [x26, #40]
	ldr	x8, [x20, #8]
	add	x8, x8, w23, uxtw
	stp	xzr, x8, [x26, #24]
	stp	w25, w23, [x26, #4]
	sub	w8, w21, #1
	stp	w23, w8, [x26, #12]
	mov	x0, x20
	mov	x1, x26
	bl	_bcmgenet_alloc_rx_buffers
	mov	x24, x0
	cbnz	w0, LBB0_2
; %bb.1:
	mov	w28, w19
Lloh11:
	adrp	x8, _bcmgenet_dim_work@GOTPAGE
Lloh12:
	ldr	x8, [x8, _bcmgenet_dim_work@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	mov	x0, x26
	bl	_bcmgenet_init_dim
	mov	x0, x26
	bl	_bcmgenet_init_rx_coalesce
	ldr	w0, [x20]
	mov	w8, #56
	madd	x8, x28, x8, x27
	add	x1, x8, #20
Lloh14:
	adrp	x8, _bcmgenet_rx_poll@GOTPAGE
Lloh15:
	ldr	x8, [x8, _bcmgenet_rx_poll@GOTPAGEOFF]
Lloh16:
	ldr	w2, [x8]
Lloh17:
	adrp	x8, _NAPI_POLL_WEIGHT@GOTPAGE
Lloh18:
	ldr	x8, [x8, _NAPI_POLL_WEIGHT@GOTPAGEOFF]
Lloh19:
	ldr	w3, [x8]
	bl	_netif_napi_add
Lloh20:
	adrp	x8, _RDMA_PROD_INDEX@GOTPAGE
Lloh21:
	ldr	x8, [x8, _RDMA_PROD_INDEX@GOTPAGEOFF]
Lloh22:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	mov	w2, #0
	bl	_bcmgenet_rdma_ring_writel
Lloh23:
	adrp	x8, _RDMA_CONS_INDEX@GOTPAGE
Lloh24:
	ldr	x8, [x8, _RDMA_CONS_INDEX@GOTPAGEOFF]
Lloh25:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	mov	w2, #0
	bl	_bcmgenet_rdma_ring_writel
Lloh26:
	adrp	x8, _DMA_RING_SIZE_SHIFT@GOTPAGE
Lloh27:
	ldr	x8, [x8, _DMA_RING_SIZE_SHIFT@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
Lloh29:
	adrp	x9, _RX_BUF_LENGTH@GOTPAGE
Lloh30:
	ldr	x9, [x9, _RX_BUF_LENGTH@GOTPAGEOFF]
	lsl	w8, w25, w8
Lloh31:
	ldr	w9, [x9]
	orr	w2, w8, w9
Lloh32:
	adrp	x8, _DMA_RING_BUF_SIZE@GOTPAGE
Lloh33:
	ldr	x8, [x8, _DMA_RING_BUF_SIZE@GOTPAGEOFF]
Lloh34:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	bl	_bcmgenet_rdma_ring_writel
Lloh35:
	adrp	x8, _DMA_FC_THRESH_LO@GOTPAGE
Lloh36:
	ldr	x8, [x8, _DMA_FC_THRESH_LO@GOTPAGEOFF]
Lloh37:
	ldr	w8, [x8]
Lloh38:
	adrp	x9, _DMA_XOFF_THRESHOLD_SHIFT@GOTPAGE
Lloh39:
	ldr	x9, [x9, _DMA_XOFF_THRESHOLD_SHIFT@GOTPAGEOFF]
Lloh40:
	ldr	w9, [x9]
Lloh41:
	adrp	x10, _DMA_FC_THRESH_HI@GOTPAGE
Lloh42:
	ldr	x10, [x10, _DMA_FC_THRESH_HI@GOTPAGEOFF]
	lsl	w8, w8, w9
Lloh43:
	ldr	w9, [x10]
	orr	w2, w8, w9
Lloh44:
	adrp	x8, _RDMA_XON_XOFF_THRESH@GOTPAGE
Lloh45:
	ldr	x8, [x8, _RDMA_XON_XOFF_THRESH@GOTPAGEOFF]
Lloh46:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	bl	_bcmgenet_rdma_ring_writel
	mul	w23, w22, w23
Lloh47:
	adrp	x8, _DMA_START_ADDR@GOTPAGE
Lloh48:
	ldr	x8, [x8, _DMA_START_ADDR@GOTPAGEOFF]
Lloh49:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	mov	x2, x23
	bl	_bcmgenet_rdma_ring_writel
Lloh50:
	adrp	x8, _RDMA_READ_PTR@GOTPAGE
Lloh51:
	ldr	x8, [x8, _RDMA_READ_PTR@GOTPAGEOFF]
Lloh52:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	mov	x2, x23
	bl	_bcmgenet_rdma_ring_writel
Lloh53:
	adrp	x8, _RDMA_WRITE_PTR@GOTPAGE
Lloh54:
	ldr	x8, [x8, _RDMA_WRITE_PTR@GOTPAGEOFF]
Lloh55:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	mov	x2, x23
	bl	_bcmgenet_rdma_ring_writel
	mul	w8, w22, w21
	sub	w2, w8, #1
Lloh56:
	adrp	x8, _DMA_END_ADDR@GOTPAGE
Lloh57:
	ldr	x8, [x8, _DMA_END_ADDR@GOTPAGEOFF]
Lloh58:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	bl	_bcmgenet_rdma_ring_writel
LBB0_2:
	mov	x0, x24
	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	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_DESC_INDEX,4,2                 ; @DESC_INDEX
	.comm	_bcmgenet_rx_ring16_int_enable,4,2 ; @bcmgenet_rx_ring16_int_enable
	.comm	_bcmgenet_rx_ring16_int_disable,4,2 ; @bcmgenet_rx_ring16_int_disable
	.comm	_bcmgenet_rx_ring_int_enable,4,2 ; @bcmgenet_rx_ring_int_enable
	.comm	_bcmgenet_rx_ring_int_disable,4,2 ; @bcmgenet_rx_ring_int_disable
	.comm	_bcmgenet_dim_work,4,2          ; @bcmgenet_dim_work
	.comm	_bcmgenet_rx_poll,4,2           ; @bcmgenet_rx_poll
	.comm	_NAPI_POLL_WEIGHT,4,2           ; @NAPI_POLL_WEIGHT
	.comm	_RDMA_PROD_INDEX,4,2            ; @RDMA_PROD_INDEX
	.comm	_RDMA_CONS_INDEX,4,2            ; @RDMA_CONS_INDEX
	.comm	_DMA_RING_SIZE_SHIFT,4,2        ; @DMA_RING_SIZE_SHIFT
	.comm	_RX_BUF_LENGTH,4,2              ; @RX_BUF_LENGTH
	.comm	_DMA_RING_BUF_SIZE,4,2          ; @DMA_RING_BUF_SIZE
	.comm	_DMA_FC_THRESH_LO,4,2           ; @DMA_FC_THRESH_LO
	.comm	_DMA_XOFF_THRESHOLD_SHIFT,4,2   ; @DMA_XOFF_THRESHOLD_SHIFT
	.comm	_DMA_FC_THRESH_HI,4,2           ; @DMA_FC_THRESH_HI
	.comm	_RDMA_XON_XOFF_THRESH,4,2       ; @RDMA_XON_XOFF_THRESH
	.comm	_DMA_START_ADDR,4,2             ; @DMA_START_ADDR
	.comm	_RDMA_READ_PTR,4,2              ; @RDMA_READ_PTR
	.comm	_RDMA_WRITE_PTR,4,2             ; @RDMA_WRITE_PTR
	.comm	_DMA_END_ADDR,4,2               ; @DMA_END_ADDR
	.no_dead_strip	_bcmgenet_init_rx_ring
.subsections_via_symbols
