	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bnx2_setup_int_mode
_bnx2_setup_int_mode:                   ## @bnx2_setup_int_mode
	.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
	movl	%esi, %r14d
	movq	%rdi, %rbx
	xorl	%eax, %eax
	callq	_netif_get_num_default_rss_queues
	movl	(%rbx), %ecx
	testl	%ecx, %ecx
	je	LBB0_1
## %bb.2:
	movl	4(%rbx), %esi
	testl	%esi, %esi
	je	LBB0_3
## %bb.4:
	movl	%ecx, %edi
	jmp	LBB0_5
LBB0_1:
	incl	%eax
	movl	4(%rbx), %esi
	movl	%eax, %edi
	jmp	LBB0_5
LBB0_3:
	movl	%eax, %edi
	movl	%ecx, %esi
LBB0_5:
	callq	_max
	movl	%eax, %edi
	movq	_RX_MAX_RINGS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_min
	movq	%rax, %r15
	movq	_bnx2_interrupt@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	48(%rbx), %rcx
	movl	%eax, 4(%rcx)
	movl	8(%rcx), %edi
	movq	24(%rbx), %rax
	movl	(%rax), %esi
	callq	_strcpy
	movl	$1, 8(%rbx)
	movq	40(%rbx), %rax
	movq	48(%rbx), %rcx
	movl	(%rax), %eax
	movl	%eax, (%rcx)
	movl	12(%rbx), %eax
	testl	%r14d, %r14d
	jne	LBB0_8
## %bb.6:
	movq	_BNX2_FLAG_MSIX_CAP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%eax, %ecx
	je	LBB0_8
## %bb.7:
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_bnx2_enable_msix
	movl	12(%rbx), %eax
LBB0_8:
	testl	%r14d, %r14d
	jne	LBB0_16
## %bb.9:
	movq	_BNX2_FLAG_MSI_CAP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%eax, %ecx
	je	LBB0_16
## %bb.10:
	movq	_BNX2_FLAG_USING_MSIX@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_16
## %bb.11:
	movq	40(%rbx), %rdi
	callq	_pci_enable_msi
	testq	%rax, %rax
	jne	LBB0_16
## %bb.12:
	movq	_BNX2_FLAG_USING_MSI@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 12(%rbx)
	movq	%rbx, %rdi
	callq	_BNX2_CHIP
	movq	_BNX2_CHIP_5709@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_13
## %bb.14:
	movq	_BNX2_FLAG_ONE_SHOT_MSI@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 12(%rbx)
	movq	_bnx2_msi_1shot@GOTPCREL(%rip), %rax
	jmp	LBB0_15
LBB0_13:
	movq	_bnx2_msi@GOTPCREL(%rip), %rax
LBB0_15:
	movl	(%rax), %eax
	movq	48(%rbx), %rcx
	movl	%eax, 4(%rcx)
	movq	40(%rbx), %rax
	movl	(%rax), %eax
	movl	%eax, (%rcx)
LBB0_16:
	movl	4(%rbx), %esi
	movl	8(%rbx), %edi
	testl	%esi, %esi
	je	LBB0_17
## %bb.18:
	callq	_min
	jmp	LBB0_19
LBB0_17:
	callq	_rounddown_pow_of_two
LBB0_19:
	movq	%rax, 32(%rbx)
	movl	(%rbx), %esi
	movl	8(%rbx), %edi
	testl	%esi, %esi
	je	LBB0_21
## %bb.20:
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_min
	movq	%rax, %rdi
	movq	32(%rbx), %rax
LBB0_21:
	movl	%edi, 16(%rbx)
	movq	24(%rbx), %rdi
	movq	%rax, %rsi
	callq	_netif_set_real_num_tx_queues
	movq	24(%rbx), %rdi
	movl	16(%rbx), %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_netif_set_real_num_rx_queues   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_RX_MAX_RINGS,4,2               ## @RX_MAX_RINGS
	.comm	_bnx2_interrupt,4,2             ## @bnx2_interrupt
	.comm	_BNX2_FLAG_MSIX_CAP,4,2         ## @BNX2_FLAG_MSIX_CAP
	.comm	_BNX2_FLAG_MSI_CAP,4,2          ## @BNX2_FLAG_MSI_CAP
	.comm	_BNX2_FLAG_USING_MSIX,4,2       ## @BNX2_FLAG_USING_MSIX
	.comm	_BNX2_FLAG_USING_MSI,4,2        ## @BNX2_FLAG_USING_MSI
	.comm	_BNX2_CHIP_5709,8,3             ## @BNX2_CHIP_5709
	.comm	_BNX2_FLAG_ONE_SHOT_MSI,4,2     ## @BNX2_FLAG_ONE_SHOT_MSI
	.comm	_bnx2_msi_1shot,4,2             ## @bnx2_msi_1shot
	.comm	_bnx2_msi,4,2                   ## @bnx2_msi
	.no_dead_strip	_bnx2_setup_int_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bnx2_setup_int_mode
_bnx2_setup_int_mode:                   ; @bnx2_setup_int_mode
	.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
	bl	_netif_get_num_default_rss_queues
	ldr	w8, [x19]
	cbz	w8, LBB0_3
; %bb.1:
	ldr	w1, [x19, #4]
	cbz	w1, LBB0_4
; %bb.2:
	mov	x0, x8
	b	LBB0_5
LBB0_3:
	add	w0, w0, #1
	ldr	w1, [x19, #4]
	b	LBB0_5
LBB0_4:
	mov	x1, x8
LBB0_5:
	bl	_max
Lloh0:
	adrp	x8, _RX_MAX_RINGS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RX_MAX_RINGS@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_min
	mov	x21, x0
Lloh3:
	adrp	x8, _bnx2_interrupt@GOTPAGE
Lloh4:
	ldr	x8, [x8, _bnx2_interrupt@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	ldr	x9, [x19, #48]
	str	w8, [x9, #4]
	ldr	w0, [x9, #8]
	ldr	x8, [x19, #24]
	ldr	w1, [x8]
	bl	_strcpy
	mov	w8, #1
	str	w8, [x19, #8]
	ldp	x8, x9, [x19, #40]
	ldr	w8, [x8]
	str	w8, [x9]
	ldr	w8, [x19, #12]
	cbnz	w20, LBB0_8
; %bb.6:
Lloh6:
	adrp	x9, _BNX2_FLAG_MSIX_CAP@GOTPAGE
Lloh7:
	ldr	x9, [x9, _BNX2_FLAG_MSIX_CAP@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	and	w9, w9, w8
	cbz	w9, LBB0_8
; %bb.7:
	mov	x0, x19
	mov	x1, x21
	bl	_bnx2_enable_msix
	ldr	w8, [x19, #12]
LBB0_8:
	cbnz	w20, LBB0_12
; %bb.9:
Lloh9:
	adrp	x9, _BNX2_FLAG_MSI_CAP@GOTPAGE
Lloh10:
	ldr	x9, [x9, _BNX2_FLAG_MSI_CAP@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	and	w9, w9, w8
	cbz	w9, LBB0_12
; %bb.10:
Lloh12:
	adrp	x9, _BNX2_FLAG_USING_MSIX@GOTPAGE
Lloh13:
	ldr	x9, [x9, _BNX2_FLAG_USING_MSIX@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_12
; %bb.11:
	ldr	x0, [x19, #40]
	bl	_pci_enable_msi
	cbz	x0, LBB0_14
LBB0_12:
	ldp	w1, w0, [x19, #4]
	cbz	w1, LBB0_18
LBB0_13:
	bl	_min
	b	LBB0_19
LBB0_14:
Lloh15:
	adrp	x8, _BNX2_FLAG_USING_MSI@GOTPAGE
Lloh16:
	ldr	x8, [x8, _BNX2_FLAG_USING_MSI@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	ldr	w9, [x19, #12]
	orr	w8, w9, w8
	str	w8, [x19, #12]
	mov	x0, x19
	bl	_BNX2_CHIP
Lloh18:
	adrp	x8, _BNX2_CHIP_5709@GOTPAGE
Lloh19:
	ldr	x8, [x8, _BNX2_CHIP_5709@GOTPAGEOFF]
Lloh20:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_16
; %bb.15:
Lloh21:
	adrp	x8, _BNX2_FLAG_ONE_SHOT_MSI@GOTPAGE
Lloh22:
	ldr	x8, [x8, _BNX2_FLAG_ONE_SHOT_MSI@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	ldr	w9, [x19, #12]
	orr	w8, w9, w8
	str	w8, [x19, #12]
Lloh24:
	adrp	x8, _bnx2_msi_1shot@GOTPAGE
Lloh25:
	ldr	x8, [x8, _bnx2_msi_1shot@GOTPAGEOFF]
	b	LBB0_17
LBB0_16:
Lloh26:
	adrp	x8, _bnx2_msi@GOTPAGE
Lloh27:
	ldr	x8, [x8, _bnx2_msi@GOTPAGEOFF]
LBB0_17:
	ldr	w8, [x8]
	ldp	x10, x9, [x19, #40]
	ldr	w10, [x10]
	stp	w10, w8, [x9]
	ldp	w1, w0, [x19, #4]
	cbnz	w1, LBB0_13
LBB0_18:
	bl	_rounddown_pow_of_two
LBB0_19:
	mov	x8, x0
	str	x0, [x19, #32]
	ldr	w1, [x19]
	ldr	w0, [x19, #8]
	cbz	w1, LBB0_21
; %bb.20:
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_min
	ldr	x8, [x19, #32]
LBB0_21:
	str	w0, [x19, #16]
	ldr	x0, [x19, #24]
	mov	x1, x8
	bl	_netif_set_real_num_tx_queues
	ldr	x0, [x19, #24]
	ldr	w1, [x19, #16]
	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	_netif_set_real_num_rx_queues
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_RX_MAX_RINGS,4,2               ; @RX_MAX_RINGS
	.comm	_bnx2_interrupt,4,2             ; @bnx2_interrupt
	.comm	_BNX2_FLAG_MSIX_CAP,4,2         ; @BNX2_FLAG_MSIX_CAP
	.comm	_BNX2_FLAG_MSI_CAP,4,2          ; @BNX2_FLAG_MSI_CAP
	.comm	_BNX2_FLAG_USING_MSIX,4,2       ; @BNX2_FLAG_USING_MSIX
	.comm	_BNX2_FLAG_USING_MSI,4,2        ; @BNX2_FLAG_USING_MSI
	.comm	_BNX2_CHIP_5709,8,3             ; @BNX2_CHIP_5709
	.comm	_BNX2_FLAG_ONE_SHOT_MSI,4,2     ; @BNX2_FLAG_ONE_SHOT_MSI
	.comm	_bnx2_msi_1shot,4,2             ; @bnx2_msi_1shot
	.comm	_bnx2_msi,4,2                   ; @bnx2_msi
	.no_dead_strip	_bnx2_setup_int_mode
.subsections_via_symbols
