	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cnic_init_bnx2_rx_ring
_cnic_init_bnx2_rx_ring:                ## @cnic_init_bnx2_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
	movq	%rdi, %r13
	movq	(%rdi), %r14
	movq	56(%r14), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	48(%r14), %rax
	movq	40(%r14), %rbx
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	(%r14), %r15d
	movl	$2, %esi
	callq	_cnic_init_context
	movq	%rbx, 8(%r14)
	movq	_BNX2_HC_COMMAND@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_CNIC_RD
	movl	%eax, %ebx
	movq	_CNIC_DRV_STATE_USING_MSIX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	testl	%eax, (%rcx)
	movq	%r15, -64(%rbp)                 ## 8-byte Spill
	je	LBB0_1
## %bb.2:
	movq	32(%r14), %rax
	movq	%rax, 8(%r14)
	movq	_BNX2_HC_COALESCE_NOW@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r12d
	leal	11(%r15), %ecx
	movl	$1, %ebx
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %ebx
	jmp	LBB0_3
LBB0_1:
	movq	8(%r14), %rax
LBB0_3:
	movq	(%rax), %rax
	testq	%rax, %rax
	jne	LBB0_7
## %bb.4:
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	movl	%r12d, %esi
	movl	%ebx, %edx
	callq	_CNIC_WR
	movl	$10, %edi
	callq	_udelay
	xorl	%eax, %eax
	callq	_barrier
	movq	8(%r14), %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	jne	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	leal	1(%r15), %ecx
	cmpl	$9, %r15d
	movl	%ecx, %r15d
	jb	LBB0_5
LBB0_7:
	movq	%rax, 16(%r14)
	movl	$2, %ebx
	movl	$2, %edi
	callq	_GET_CID_ADDR
	movq	_BNX2_L2CTX_CTX_TYPE_CTX_BD_CHN_TYPE_VALUE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	_BNX2_L2CTX_CTX_TYPE_SIZE_L2@GOTPCREL(%rip), %rdx
	orl	(%rdx), %ecx
	movl	%eax, %r12d
	orl	$512, %ecx                      ## imm = 0x200
	movq	_BNX2_L2CTX_CTX_TYPE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_cnic_ctx_wr
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	testl	%edi, %edi
	je	LBB0_8
## %bb.9:
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_BNX2_L2CTX_L2_STATUSB_NUM
	movl	%eax, %ebx
	jmp	LBB0_10
LBB0_8:
	movq	_BNX2_L2CTX_L2_STATUSB_NUM_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %ebx
LBB0_10:
	movq	_BNX2_L2CTX_HOST_BDIDX@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	movl	%r12d, %esi
	movl	%ebx, %ecx
	callq	_cnic_ctx_wr
	movq	_CNIC_PAGE_SIZE@GOTPCREL(%rip), %r15
	movslq	(%r15), %rbx
	shlq	$4, %rbx
	movq	_BNX2_MAX_RX_DESC_CNT@GOTPCREL(%rip), %r8
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	addq	8(%rax), %rbx
	cmpl	$0, (%r8)
	jle	LBB0_13
## %bb.11:
	movl	24(%r14), %r9d
	movl	28(%r14), %esi
	movl	4(%rax), %edi
	xorl	%ecx, %ecx
	movq	_RX_BD_FLAGS_START@GOTPCREL(%rip), %r10
	movq	_RX_BD_FLAGS_END@GOTPCREL(%rip), %r11
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movl	%ecx, %eax
	cltd
	idivl	%r9d
	incl	%edx
	imull	%esi, %edx
	addl	%edi, %edx
	movl	%esi, (%rbx)
	movl	(%r11), %eax
	orl	(%r10), %eax
	movl	%eax, 4(%rbx)
	movl	%edx, 12(%rbx)
	incl	%ecx
	addq	$16, %rbx
	cmpl	(%r8), %ecx
	jl	LBB0_12
LBB0_13:
	movl	-44(%rbp), %r14d                ## 4-byte Reload
	movq	_BNX2_L2CTX_NX_BDHADDR_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_cnic_ctx_wr
	addl	(%r15), %r14d
	movq	_BNX2_L2CTX_NX_BDHADDR_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	movl	%r12d, %esi
	movl	%r14d, %ecx
	callq	_cnic_ctx_wr
	movl	%r14d, 12(%rbx)
	movq	_BNX2_RXP_SCRATCH_RXP_FLOOD@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r13, %rdi
	callq	_cnic_reg_rd_ind
	movl	(%rbx), %esi
	orl	$4, %eax
	movq	%r13, %rdi
	movl	%eax, %edx
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_cnic_reg_wr_ind                ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_BNX2_HC_COMMAND,4,2            ## @BNX2_HC_COMMAND
	.comm	_CNIC_DRV_STATE_USING_MSIX,4,2  ## @CNIC_DRV_STATE_USING_MSIX
	.comm	_BNX2_HC_COALESCE_NOW,4,2       ## @BNX2_HC_COALESCE_NOW
	.comm	_BNX2_L2CTX_CTX_TYPE_CTX_BD_CHN_TYPE_VALUE,4,2 ## @BNX2_L2CTX_CTX_TYPE_CTX_BD_CHN_TYPE_VALUE
	.comm	_BNX2_L2CTX_CTX_TYPE_SIZE_L2,4,2 ## @BNX2_L2CTX_CTX_TYPE_SIZE_L2
	.comm	_BNX2_L2CTX_CTX_TYPE,4,2        ## @BNX2_L2CTX_CTX_TYPE
	.comm	_BNX2_L2CTX_L2_STATUSB_NUM_SHIFT,4,2 ## @BNX2_L2CTX_L2_STATUSB_NUM_SHIFT
	.comm	_BNX2_L2CTX_HOST_BDIDX,4,2      ## @BNX2_L2CTX_HOST_BDIDX
	.comm	_CNIC_PAGE_SIZE,4,2             ## @CNIC_PAGE_SIZE
	.comm	_BNX2_MAX_RX_DESC_CNT,4,2       ## @BNX2_MAX_RX_DESC_CNT
	.comm	_RX_BD_FLAGS_START,4,2          ## @RX_BD_FLAGS_START
	.comm	_RX_BD_FLAGS_END,4,2            ## @RX_BD_FLAGS_END
	.comm	_BNX2_L2CTX_NX_BDHADDR_HI,4,2   ## @BNX2_L2CTX_NX_BDHADDR_HI
	.comm	_BNX2_L2CTX_NX_BDHADDR_LO,4,2   ## @BNX2_L2CTX_NX_BDHADDR_LO
	.comm	_BNX2_RXP_SCRATCH_RXP_FLOOD,4,2 ## @BNX2_RXP_SCRATCH_RXP_FLOOD
	.no_dead_strip	_cnic_init_bnx2_rx_ring
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cnic_init_bnx2_rx_ring
_cnic_init_bnx2_rx_ring:                ; @cnic_init_bnx2_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	x19, x0
	ldr	x24, [x0]
	ldp	x25, x26, [x24, #48]
	ldr	x21, [x24, #40]
	ldr	w23, [x25]
	ldr	w20, [x24]
	mov	w1, #2
	bl	_cnic_init_context
	str	x21, [x24, #8]
Lloh0:
	adrp	x8, _BNX2_HC_COMMAND@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BNX2_HC_COMMAND@GOTPAGEOFF]
Lloh2:
	ldr	w21, [x8]
	mov	x0, x19
	mov	x1, x21
	bl	_CNIC_RD
	ldr	w8, [x26]
Lloh3:
	adrp	x9, _CNIC_DRV_STATE_USING_MSIX@GOTPAGE
Lloh4:
	ldr	x9, [x9, _CNIC_DRV_STATE_USING_MSIX@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.1:
	ldr	x8, [x24, #32]
	str	x8, [x24, #8]
Lloh6:
	adrp	x9, _BNX2_HC_COALESCE_NOW@GOTPAGE
Lloh7:
	ldr	x9, [x9, _BNX2_HC_COALESCE_NOW@GOTPAGEOFF]
Lloh8:
	ldr	w21, [x9]
	add	w9, w20, #11
	mov	w10, #1
	lsl	w22, w10, w9
	ldr	x8, [x8]
	cbnz	x8, LBB0_5
	b	LBB0_3
LBB0_2:
	mov	x22, x0
	ldr	x8, [x24, #8]
	ldr	x8, [x8]
	cbnz	x8, LBB0_5
LBB0_3:
	mov	w26, #0
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	mov	x1, x21
	mov	x2, x22
	bl	_CNIC_WR
	mov	w0, #10
	bl	_udelay
	add	w27, w26, #1
	bl	_barrier
	ldr	x8, [x24, #8]
	ldr	x8, [x8]
	cmp	x8, #0
	ccmp	w26, #9, #2, eq
	mov	x26, x27
	b.lo	LBB0_4
LBB0_5:
	str	x8, [x24, #16]
	mov	w22, #2
	mov	w0, #2
	bl	_GET_CID_ADDR
	mov	x21, x0
Lloh9:
	adrp	x8, _BNX2_L2CTX_CTX_TYPE_CTX_BD_CHN_TYPE_VALUE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BNX2_L2CTX_CTX_TYPE_CTX_BD_CHN_TYPE_VALUE@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
Lloh12:
	adrp	x9, _BNX2_L2CTX_CTX_TYPE_SIZE_L2@GOTPAGE
Lloh13:
	ldr	x9, [x9, _BNX2_L2CTX_CTX_TYPE_SIZE_L2@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	orr	w8, w8, w9
	orr	w3, w8, #0x200
Lloh15:
	adrp	x8, _BNX2_L2CTX_CTX_TYPE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _BNX2_L2CTX_CTX_TYPE@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x21
	bl	_cnic_ctx_wr
	cbz	w20, LBB0_7
; %bb.6:
	mov	x0, x20
	bl	_BNX2_L2CTX_L2_STATUSB_NUM
	mov	x3, x0
	b	LBB0_8
LBB0_7:
Lloh18:
	adrp	x8, _BNX2_L2CTX_L2_STATUSB_NUM_SHIFT@GOTPAGE
Lloh19:
	ldr	x8, [x8, _BNX2_L2CTX_L2_STATUSB_NUM_SHIFT@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	lsl	w3, w22, w8
LBB0_8:
Lloh21:
	adrp	x8, _BNX2_L2CTX_HOST_BDIDX@GOTPAGE
Lloh22:
	ldr	x8, [x8, _BNX2_L2CTX_HOST_BDIDX@GOTPAGEOFF]
Lloh23:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x21
	bl	_cnic_ctx_wr
	ldr	x8, [x25, #8]
Lloh24:
	adrp	x20, _CNIC_PAGE_SIZE@GOTPAGE
Lloh25:
	ldr	x20, [x20, _CNIC_PAGE_SIZE@GOTPAGEOFF]
	ldrsw	x9, [x20]
	add	x22, x8, x9, lsl #4
Lloh26:
	adrp	x8, _BNX2_MAX_RX_DESC_CNT@GOTPAGE
Lloh27:
	ldr	x8, [x8, _BNX2_MAX_RX_DESC_CNT@GOTPAGEOFF]
	ldr	w9, [x8]
	cmp	w9, #1
	b.lt	LBB0_11
; %bb.9:
	mov	w9, #0
	ldr	w10, [x25, #4]
	ldp	w11, w12, [x24, #24]
Lloh28:
	adrp	x13, _RX_BD_FLAGS_START@GOTPAGE
Lloh29:
	ldr	x13, [x13, _RX_BD_FLAGS_START@GOTPAGEOFF]
Lloh30:
	adrp	x14, _RX_BD_FLAGS_END@GOTPAGE
Lloh31:
	ldr	x14, [x14, _RX_BD_FLAGS_END@GOTPAGEOFF]
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	sdiv	w15, w9, w11
	msub	w15, w15, w11, w9
	madd	w15, w12, w15, w12
	add	w15, w15, w10
	str	w12, [x22]
	ldr	w16, [x13]
	ldr	w17, [x14]
	orr	w16, w17, w16
	str	w16, [x22, #4]
	str	w15, [x22, #12]
	add	w9, w9, #1
	add	x22, x22, #16
	ldr	w15, [x8]
	cmp	w9, w15
	b.lt	LBB0_10
LBB0_11:
Lloh32:
	adrp	x8, _BNX2_L2CTX_NX_BDHADDR_HI@GOTPAGE
Lloh33:
	ldr	x8, [x8, _BNX2_L2CTX_NX_BDHADDR_HI@GOTPAGEOFF]
Lloh34:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x21
	bl	_cnic_ctx_wr
	ldr	w8, [x20]
	add	w20, w8, w23
Lloh35:
	adrp	x8, _BNX2_L2CTX_NX_BDHADDR_LO@GOTPAGE
Lloh36:
	ldr	x8, [x8, _BNX2_L2CTX_NX_BDHADDR_LO@GOTPAGEOFF]
Lloh37:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x21
	mov	x3, x20
	bl	_cnic_ctx_wr
	str	w20, [x22, #12]
Lloh38:
	adrp	x20, _BNX2_RXP_SCRATCH_RXP_FLOOD@GOTPAGE
Lloh39:
	ldr	x20, [x20, _BNX2_RXP_SCRATCH_RXP_FLOOD@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	bl	_cnic_reg_rd_ind
	ldr	w1, [x20]
	orr	w2, w0, #0x4
	mov	x0, x19
	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
	b	_cnic_reg_wr_ind
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_BNX2_HC_COMMAND,4,2            ; @BNX2_HC_COMMAND
	.comm	_CNIC_DRV_STATE_USING_MSIX,4,2  ; @CNIC_DRV_STATE_USING_MSIX
	.comm	_BNX2_HC_COALESCE_NOW,4,2       ; @BNX2_HC_COALESCE_NOW
	.comm	_BNX2_L2CTX_CTX_TYPE_CTX_BD_CHN_TYPE_VALUE,4,2 ; @BNX2_L2CTX_CTX_TYPE_CTX_BD_CHN_TYPE_VALUE
	.comm	_BNX2_L2CTX_CTX_TYPE_SIZE_L2,4,2 ; @BNX2_L2CTX_CTX_TYPE_SIZE_L2
	.comm	_BNX2_L2CTX_CTX_TYPE,4,2        ; @BNX2_L2CTX_CTX_TYPE
	.comm	_BNX2_L2CTX_L2_STATUSB_NUM_SHIFT,4,2 ; @BNX2_L2CTX_L2_STATUSB_NUM_SHIFT
	.comm	_BNX2_L2CTX_HOST_BDIDX,4,2      ; @BNX2_L2CTX_HOST_BDIDX
	.comm	_CNIC_PAGE_SIZE,4,2             ; @CNIC_PAGE_SIZE
	.comm	_BNX2_MAX_RX_DESC_CNT,4,2       ; @BNX2_MAX_RX_DESC_CNT
	.comm	_RX_BD_FLAGS_START,4,2          ; @RX_BD_FLAGS_START
	.comm	_RX_BD_FLAGS_END,4,2            ; @RX_BD_FLAGS_END
	.comm	_BNX2_L2CTX_NX_BDHADDR_HI,4,2   ; @BNX2_L2CTX_NX_BDHADDR_HI
	.comm	_BNX2_L2CTX_NX_BDHADDR_LO,4,2   ; @BNX2_L2CTX_NX_BDHADDR_LO
	.comm	_BNX2_RXP_SCRATCH_RXP_FLOOD,4,2 ; @BNX2_RXP_SCRATCH_RXP_FLOOD
	.no_dead_strip	_cnic_init_bnx2_rx_ring
.subsections_via_symbols
