	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bnx2_set_channels
_bnx2_set_channels:                     ## @bnx2_set_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	callq	_netdev_priv
	movq	%rax, %r15
	movq	_BNX2_FLAG_MSIX_CAP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r15)
	sete	%al
	movq	_disable_msi@GOTPCREL(%rip), %rcx
	cmpl	$0, (%rcx)
	setne	%cl
	orb	%al, %cl
	movl	$1, %edx
	jne	LBB0_2
## %bb.1:
	movq	_RX_MAX_RINGS@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
LBB0_2:
	movq	(%rbx), %rax
	cmpq	%rdx, %rax
	jg	LBB0_6
## %bb.3:
	movl	$1, %edx
	testb	%cl, %cl
	jne	LBB0_5
## %bb.4:
	movq	_TX_MAX_RINGS@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
LBB0_5:
	movq	8(%rbx), %rcx
	cmpq	%rdx, %rcx
	jle	LBB0_7
LBB0_6:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	%rax, 8(%r15)
	movq	%rcx, 16(%r15)
	movq	%r14, %rdi
	callq	_netif_running
	testq	%rax, %rax
	je	LBB0_8
## %bb.10:
	movl	24(%r15), %edx
	movl	28(%r15), %esi
	movq	%r15, %rdi
	movl	$1, %ecx
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_bnx2_change_ring_size          ## TAILCALL
LBB0_8:
	xorl	%eax, %eax
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_BNX2_FLAG_MSIX_CAP,4,2         ## @BNX2_FLAG_MSIX_CAP
	.comm	_disable_msi,4,2                ## @disable_msi
	.comm	_RX_MAX_RINGS,8,3               ## @RX_MAX_RINGS
	.comm	_TX_MAX_RINGS,8,3               ## @TX_MAX_RINGS
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_bnx2_set_channels
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bnx2_set_channels
_bnx2_set_channels:                     ; @bnx2_set_channels
	.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	x21, x1
	mov	x20, x0
	bl	_netdev_priv
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _BNX2_FLAG_MSIX_CAP@GOTPAGE
Lloh1:
	ldr	x9, [x9, _BNX2_FLAG_MSIX_CAP@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
Lloh3:
	adrp	x8, _disable_msi@GOTPAGE
Lloh4:
	ldr	x8, [x8, _disable_msi@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	ccmp	w8, #0, #0, ne
	cset	w9, ne
Lloh6:
	adrp	x8, _RX_MAX_RINGS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _RX_MAX_RINGS@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	csinc	x10, x8, xzr, eq
	ldr	x8, [x21]
	cmp	x8, x10
	b.gt	LBB0_2
; %bb.1:
Lloh9:
	adrp	x10, _TX_MAX_RINGS@GOTPAGE
Lloh10:
	ldr	x10, [x10, _TX_MAX_RINGS@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
	cmp	w9, #0
	csinc	x10, x10, xzr, eq
	ldr	x9, [x21, #8]
	cmp	x9, x10
	b.le	LBB0_4
LBB0_2:
Lloh12:
	adrp	x8, _EINVAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_3:
	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
LBB0_4:
	mov	x19, x0
	stp	x8, x9, [x0, #8]
	mov	x0, x20
	bl	_netif_running
	cbz	x0, LBB0_3
; %bb.5:
	ldp	w2, w1, [x19, #24]
	mov	x0, x19
	mov	w3, #1
	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
	b	_bnx2_change_ring_size
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_BNX2_FLAG_MSIX_CAP,4,2         ; @BNX2_FLAG_MSIX_CAP
	.comm	_disable_msi,4,2                ; @disable_msi
	.comm	_RX_MAX_RINGS,8,3               ; @RX_MAX_RINGS
	.comm	_TX_MAX_RINGS,8,3               ; @TX_MAX_RINGS
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_bnx2_set_channels
.subsections_via_symbols
