	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lio_ethtool_get_channels
_lio_ethtool_get_channels:              ## @lio_ethtool_get_channels
	.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	%rsi, %r14
	callq	_GET_LIO
	movq	%rax, %rbx
	movq	16(%rax), %r12
	movq	%r12, %rdi
	callq	_OCTEON_CN6XXX
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_cn6xxx@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_CHIP_CONF
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_CFG_GET_OQ_MAX_Q
	movq	%rax, %r12
	movq	%r15, %rdi
	callq	_CFG_GET_IQ_MAX_Q
	movq	%rax, %r13
	movl	8(%rbx), %esi
	movq	%r15, %rdi
	callq	_CFG_GET_NUM_RXQS_NIC_IF
	movl	8(%rbx), %esi
	movq	%rax, %rbx
	movq	%r15, %rdi
	callq	_CFG_GET_NUM_TXQS_NIC_IF
	movq	%rax, %rcx
	xorl	%edx, %edx
	xorl	%eax, %eax
	jmp	LBB0_11
LBB0_2:
	movq	%r12, %rdi
	callq	_OCTEON_CN23XX_PF
	testq	%rax, %rax
	je	LBB0_5
## %bb.3:
	cmpq	$0, 8(%r12)
	je	LBB0_7
## %bb.4:
	movq	(%rbx), %rax
	jmp	LBB0_8
LBB0_5:
	movq	%r12, %rdi
	callq	_OCTEON_CN23XX_VF
	testq	%rax, %rax
	je	LBB0_12
## %bb.6:
	xorl	%ebx, %ebx
	xorl	%edi, %edi
	callq	_CN23XX_VF_SLI_IQ_PKT_CONTROL64
	movq	%r12, %rdi
	movl	%eax, %esi
	callq	_octeon_read_csr64
	movq	_CN23XX_PKT_INPUT_CTL_RPVF_POS@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %eax
	movq	_CN23XX_PKT_INPUT_CTL_RPVF_MASK@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	cltq
	movq	(%r12), %rdx
	jmp	LBB0_10
LBB0_7:
	movq	_cn23xx_pf@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_CHIP_CONF
	movq	%rax, %rdi
	callq	_CFG_GET_IQ_MAX_Q
LBB0_8:
	movq	(%r12), %rdx
LBB0_9:
	xorl	%ebx, %ebx
LBB0_10:
	xorl	%ecx, %ecx
	xorl	%r13d, %r13d
	xorl	%r12d, %r12d
LBB0_11:
	movq	%r12, 40(%r14)
	movq	%r13, 32(%r14)
	movq	%rax, 24(%r14)
	movq	%rbx, 16(%r14)
	movq	%rcx, 8(%r14)
	movq	%rdx, (%r14)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	xorl	%edx, %edx
	xorl	%eax, %eax
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_cn6xxx,4,2                     ## @cn6xxx
	.comm	_cn23xx_pf,4,2                  ## @cn23xx_pf
	.comm	_CN23XX_PKT_INPUT_CTL_RPVF_POS,4,2 ## @CN23XX_PKT_INPUT_CTL_RPVF_POS
	.comm	_CN23XX_PKT_INPUT_CTL_RPVF_MASK,4,2 ## @CN23XX_PKT_INPUT_CTL_RPVF_MASK
	.no_dead_strip	_lio_ethtool_get_channels
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lio_ethtool_get_channels
_lio_ethtool_get_channels:              ; @lio_ethtool_get_channels
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x1
	bl	_GET_LIO
	mov	x24, x0
	ldr	x22, [x0, #16]
	mov	x0, x22
	bl	_OCTEON_CN6XXX
	cbz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _cn6xxx@GOTPAGE
Lloh1:
	ldr	x8, [x8, _cn6xxx@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x22
	bl	_CHIP_CONF
	mov	x22, x0
	bl	_CFG_GET_OQ_MAX_Q
	mov	x20, x0
	mov	x0, x22
	bl	_CFG_GET_IQ_MAX_Q
	mov	x21, x0
	ldr	w1, [x24, #8]
	mov	x0, x22
	bl	_CFG_GET_NUM_RXQS_NIC_IF
	mov	x23, x0
	ldr	w1, [x24, #8]
	mov	x0, x22
	bl	_CFG_GET_NUM_TXQS_NIC_IF
	mov	x9, #0
	mov	x8, #0
	b	LBB0_9
LBB0_2:
	mov	x0, x22
	bl	_OCTEON_CN23XX_PF
	cbz	x0, LBB0_5
; %bb.3:
	ldr	x8, [x22, #8]
	cbz	x8, LBB0_7
; %bb.4:
	ldr	x8, [x24]
	b	LBB0_8
LBB0_5:
	mov	x0, x22
	bl	_OCTEON_CN23XX_VF
	cbz	x0, LBB0_10
; %bb.6:
	mov	w0, #0
	bl	_CN23XX_VF_SLI_IQ_PKT_CONTROL64
	mov	x1, x0
	mov	x0, x22
	bl	_octeon_read_csr64
	mov	x8, x0
	mov	x23, #0
	mov	x0, #0
	mov	x21, #0
	mov	x20, #0
	ldr	x9, [x22]
Lloh3:
	adrp	x10, _CN23XX_PKT_INPUT_CTL_RPVF_POS@GOTPAGE
Lloh4:
	ldr	x10, [x10, _CN23XX_PKT_INPUT_CTL_RPVF_POS@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	asr	w8, w8, w10
Lloh6:
	adrp	x10, _CN23XX_PKT_INPUT_CTL_RPVF_MASK@GOTPAGE
Lloh7:
	ldr	x10, [x10, _CN23XX_PKT_INPUT_CTL_RPVF_MASK@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	and	w8, w8, w10
	sxtw	x8, w8
	b	LBB0_9
LBB0_7:
Lloh9:
	adrp	x8, _cn23xx_pf@GOTPAGE
Lloh10:
	ldr	x8, [x8, _cn23xx_pf@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x22
	bl	_CHIP_CONF
	bl	_CFG_GET_IQ_MAX_Q
	mov	x8, x0
LBB0_8:
	mov	x23, #0
	mov	x0, #0
	mov	x21, #0
	mov	x20, #0
	ldr	x9, [x22]
LBB0_9:
	stp	x21, x20, [x19, #32]
	stp	x23, x8, [x19, #16]
	stp	x9, x0, [x19]
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_10:
	mov	x9, #0
	mov	x8, #0
	mov	x23, #0
	mov	x21, #0
	mov	x20, #0
	b	LBB0_9
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_cn6xxx,4,2                     ; @cn6xxx
	.comm	_cn23xx_pf,4,2                  ; @cn23xx_pf
	.comm	_CN23XX_PKT_INPUT_CTL_RPVF_POS,4,2 ; @CN23XX_PKT_INPUT_CTL_RPVF_POS
	.comm	_CN23XX_PKT_INPUT_CTL_RPVF_MASK,4,2 ; @CN23XX_PKT_INPUT_CTL_RPVF_MASK
	.no_dead_strip	_lio_ethtool_get_channels
.subsections_via_symbols
