	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function octeon_mgmt_receive_packets
_octeon_mgmt_receive_packets:           ## @octeon_mgmt_receive_packets
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r15d
	movq	%rdi, %r14
	movq	_MIX_IRCNT@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	addq	8(%r14), %rdi
	callq	_cvmx_read_csr
	xorl	%ebx, %ebx
	testl	%r15d, %r15d
	je	LBB0_5
## %bb.1:
	testq	%rax, %rax
	je	LBB0_5
## %bb.2:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_octeon_mgmt_receive_one
	cmpl	$1, %eax
	adcl	$0, %ebx
	movq	(%r12), %rdi
	addq	8(%r14), %rdi
	callq	_cvmx_read_csr
	cmpl	%r15d, %ebx
	jae	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	testq	%rax, %rax
	jne	LBB0_3
LBB0_5:
	movl	(%r14), %edi
	callq	_octeon_mgmt_rx_fill_ring
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MIX_IRCNT,8,3                  ## @MIX_IRCNT
	.no_dead_strip	_octeon_mgmt_receive_packets
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function octeon_mgmt_receive_packets
_octeon_mgmt_receive_packets:           ; @octeon_mgmt_receive_packets
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x20, x1
	mov	x19, x0
	ldr	x8, [x0, #8]
Lloh0:
	adrp	x22, _MIX_IRCNT@GOTPAGE
Lloh1:
	ldr	x22, [x22, _MIX_IRCNT@GOTPAGEOFF]
	ldr	x9, [x22]
	add	x0, x9, x8
	bl	_cvmx_read_csr
	mov	w21, #0
	cbz	w20, LBB0_4
; %bb.1:
	cbz	x0, LBB0_4
; %bb.2:
	mov	w21, #0
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_octeon_mgmt_receive_one
	cmp	w0, #0
	cinc	w21, w21, eq
	ldr	x8, [x19, #8]
	ldr	x9, [x22]
	add	x0, x9, x8
	bl	_cvmx_read_csr
	cmp	w21, w20
	ccmp	x0, #0, #4, lo
	b.ne	LBB0_3
LBB0_4:
	ldr	w0, [x19]
	bl	_octeon_mgmt_rx_fill_ring
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_MIX_IRCNT,8,3                  ; @MIX_IRCNT
	.no_dead_strip	_octeon_mgmt_receive_packets
.subsections_via_symbols
