	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bnx2_enable_msix
_bnx2_enable_msix:                      ## @bnx2_enable_msix
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_BNX2_MAX_MSIX_VEC@GOTPCREL(%rip), %r14
	movl	(%r14), %eax
	shlq	$4, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r13
	movq	24(%rbx), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_bnx2_setup_msix_tbl
	movq	_BNX2_PCI_MSIX_CONTROL@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	_BNX2_MAX_MSIX_HW_VEC@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	decq	%rdx
	movq	%rbx, %rdi
	callq	_BNX2_WR
	movq	_BNX2_PCI_MSIX_TBL_OFF_BIR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_BNX2_PCI_GRC_WINDOW2_BASE@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movq	%rbx, %rdi
	callq	_BNX2_WR
	movq	_BNX2_PCI_MSIX_PBA_OFF_BIT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_BNX2_PCI_GRC_WINDOW3_BASE@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movq	%rbx, %rdi
	callq	_BNX2_WR
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_BNX2_RD
	movl	(%r14), %eax
	testl	%eax, %eax
	jle	LBB0_7
## %bb.1:
	cmpl	$1, %eax
	jne	LBB0_3
## %bb.2:
	xorl	%ecx, %ecx
	jmp	LBB0_5
LBB0_3:
	movl	%eax, %edx
	andl	$-2, %edx
	movq	%r13, %rsi
	addq	$24, %rsi
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ecx, -24(%rsi)
	movq	$0, -16(%rsi)
	leal	1(%rcx), %edi
	movl	%edi, -8(%rsi)
	movq	$0, (%rsi)
	addq	$2, %rcx
	addq	$32, %rsi
	cmpq	%rdx, %rcx
	jne	LBB0_4
LBB0_5:
	testb	$1, %al
	je	LBB0_7
## %bb.6:
	movq	%rcx, %rax
	shlq	$4, %rax
	movl	%ecx, (%r13,%rax)
	movq	$0, 8(%r13,%rax)
LBB0_7:
	movl	16(%rbx), %edi
	movq	_BNX2_MIN_MSIX_VEC@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rsi
	movl	%r15d, %ecx
	callq	_pci_enable_msix_range
	testl	%eax, %eax
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	js	LBB0_11
## %bb.8:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	%eax, (%rdi)
	movq	_BNX2_FLAG_USING_MSIX@GOTPCREL(%rip), %rcx
	movq	_BNX2_FLAG_ONE_SHOT_MSI@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	orl	%edx, 4(%rdi)
	testl	%eax, %eax
	je	LBB0_11
## %bb.9:
	movq	%r13, %r12
	movl	%eax, %r13d
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax), %rax
	shlq	$4, %r13
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r12,%r14), %rcx
	movq	%rcx, 8(%rax,%r14)
	movl	4(%rax,%r14), %edi
	movq	(%r15), %rcx
	movl	$4, %esi
	leaq	L_.str(%rip), %rdx
	movl	%ebx, %r8d
	callq	_snprintf
	movq	_bnx2_msi_1shot@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax), %rax
	movl	%ecx, (%rax,%r14)
	incl	%ebx
	addq	$16, %r14
	cmpq	%r14, %r13
	jne	LBB0_10
LBB0_11:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_13
## %bb.12:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_BNX2_MAX_MSIX_VEC,4,2          ## @BNX2_MAX_MSIX_VEC
	.comm	_BNX2_PCI_MSIX_CONTROL,4,2      ## @BNX2_PCI_MSIX_CONTROL
	.comm	_BNX2_MAX_MSIX_HW_VEC,8,3       ## @BNX2_MAX_MSIX_HW_VEC
	.comm	_BNX2_PCI_MSIX_TBL_OFF_BIR,4,2  ## @BNX2_PCI_MSIX_TBL_OFF_BIR
	.comm	_BNX2_PCI_GRC_WINDOW2_BASE,8,3  ## @BNX2_PCI_GRC_WINDOW2_BASE
	.comm	_BNX2_PCI_MSIX_PBA_OFF_BIT,4,2  ## @BNX2_PCI_MSIX_PBA_OFF_BIT
	.comm	_BNX2_PCI_GRC_WINDOW3_BASE,8,3  ## @BNX2_PCI_GRC_WINDOW3_BASE
	.comm	_BNX2_MIN_MSIX_VEC,4,2          ## @BNX2_MIN_MSIX_VEC
	.comm	_BNX2_FLAG_USING_MSIX,4,2       ## @BNX2_FLAG_USING_MSIX
	.comm	_BNX2_FLAG_ONE_SHOT_MSI,4,2     ## @BNX2_FLAG_ONE_SHOT_MSI
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s-%d"

	.comm	_bnx2_msi_1shot,4,2             ## @bnx2_msi_1shot
	.no_dead_strip	_bnx2_enable_msix
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bnx2_enable_msix
_bnx2_enable_msix:                      ; @bnx2_enable_msix
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	sub	sp, sp, #16
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
Lloh3:
	adrp	x23, _BNX2_MAX_MSIX_VEC@GOTPAGE
Lloh4:
	ldr	x23, [x23, _BNX2_MAX_MSIX_VEC@GOTPAGEOFF]
	ldr	w8, [x23]
	lsl	x8, x8, #4
	mov	x9, x8
Lloh5:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh6:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	sub	x20, x9, x8
	mov	sp, x20
	ldr	x22, [x0, #24]
	bl	_bnx2_setup_msix_tbl
Lloh7:
	adrp	x24, _BNX2_PCI_MSIX_CONTROL@GOTPAGE
Lloh8:
	ldr	x24, [x24, _BNX2_PCI_MSIX_CONTROL@GOTPAGEOFF]
	ldr	w1, [x24]
Lloh9:
	adrp	x8, _BNX2_MAX_MSIX_HW_VEC@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BNX2_MAX_MSIX_HW_VEC@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	sub	x2, x8, #1
	mov	x0, x19
	bl	_BNX2_WR
Lloh12:
	adrp	x8, _BNX2_PCI_MSIX_TBL_OFF_BIR@GOTPAGE
Lloh13:
	ldr	x8, [x8, _BNX2_PCI_MSIX_TBL_OFF_BIR@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
Lloh15:
	adrp	x8, _BNX2_PCI_GRC_WINDOW2_BASE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _BNX2_PCI_GRC_WINDOW2_BASE@GOTPAGEOFF]
Lloh17:
	ldr	x2, [x8]
	mov	x0, x19
	bl	_BNX2_WR
Lloh18:
	adrp	x8, _BNX2_PCI_MSIX_PBA_OFF_BIT@GOTPAGE
Lloh19:
	ldr	x8, [x8, _BNX2_PCI_MSIX_PBA_OFF_BIT@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
Lloh21:
	adrp	x8, _BNX2_PCI_GRC_WINDOW3_BASE@GOTPAGE
Lloh22:
	ldr	x8, [x8, _BNX2_PCI_GRC_WINDOW3_BASE@GOTPAGEOFF]
Lloh23:
	ldr	x2, [x8]
	mov	x0, x19
	bl	_BNX2_WR
	ldr	w1, [x24]
	mov	x0, x19
	bl	_BNX2_RD
	ldr	w8, [x23]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.1:
	cmp	w8, #4
	b.hs	LBB0_3
; %bb.2:
	mov	x9, #0
	b	LBB0_6
LBB0_3:
	mov	x10, #0
	and	x9, x8, #0xfffffffc
	add	x11, x20, #32
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	add	w12, w10, #1
	stur	w10, [x11, #-32]
	add	w13, w10, #2
	add	w14, w10, #3
	stur	w12, [x11, #-16]
	str	w13, [x11]
	str	w14, [x11, #16]
	stur	xzr, [x11, #-24]
	stur	xzr, [x11, #-8]
	add	x10, x10, #4
	str	xzr, [x11, #8]
	str	xzr, [x11, #24]
	add	x11, x11, #64
	cmp	x9, x10
	b.ne	LBB0_4
; %bb.5:
	cmp	x9, x8
	b.eq	LBB0_8
LBB0_6:
	add	x10, x20, x9, lsl #4
	add	x10, x10, #8
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	stur	w9, [x10, #-8]
	str	xzr, [x10], #16
	add	x9, x9, #1
	cmp	x8, x9
	b.ne	LBB0_7
LBB0_8:
	ldr	w0, [x19, #16]
Lloh24:
	adrp	x8, _BNX2_MIN_MSIX_VEC@GOTPAGE
Lloh25:
	ldr	x8, [x8, _BNX2_MIN_MSIX_VEC@GOTPAGEOFF]
Lloh26:
	ldr	w2, [x8]
	mov	x1, x20
	mov	x3, x21
	bl	_pci_enable_msix_range
	tbnz	w0, #31, LBB0_12
; %bb.9:
	str	w0, [x19]
Lloh27:
	adrp	x8, _BNX2_FLAG_USING_MSIX@GOTPAGE
Lloh28:
	ldr	x8, [x8, _BNX2_FLAG_USING_MSIX@GOTPAGEOFF]
Lloh29:
	adrp	x9, _BNX2_FLAG_ONE_SHOT_MSI@GOTPAGE
Lloh30:
	ldr	x9, [x9, _BNX2_FLAG_ONE_SHOT_MSI@GOTPAGEOFF]
Lloh31:
	ldr	w8, [x8]
Lloh32:
	ldr	w9, [x9]
	orr	w8, w9, w8
	ldr	w9, [x19, #4]
	orr	w8, w8, w9
	str	w8, [x19, #4]
	cbz	w0, LBB0_12
; %bb.10:
	mov	x23, #0
	mov	w21, #0
	mov	w9, w0
	ldr	x8, [x19, #8]
	add	x24, x20, #8
	lsl	x25, x9, #4
Lloh33:
	adrp	x20, l_.str@PAGE
Lloh34:
	add	x20, x20, l_.str@PAGEOFF
Lloh35:
	adrp	x26, _bnx2_msi_1shot@GOTPAGE
Lloh36:
	ldr	x26, [x26, _bnx2_msi_1shot@GOTPAGEOFF]
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x24, x23]
	add	x8, x8, x23
	str	x9, [x8, #8]
	ldr	w0, [x8, #4]
	ldr	x3, [x22]
	mov	w1, #4
	mov	x2, x20
	mov	x4, x21
	bl	_snprintf
	ldr	w9, [x26]
	ldr	x8, [x19, #8]
	str	w9, [x8, x23]
	add	w21, w21, #1
	add	x23, x23, #16
	cmp	x25, x23
	b.ne	LBB0_11
LBB0_12:
	ldur	x8, [x29, #-72]
Lloh37:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh38:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh39:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.13:
	sub	sp, x29, #64
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh31
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.cfi_endproc
                                        ; -- End function
	.comm	_BNX2_MAX_MSIX_VEC,4,2          ; @BNX2_MAX_MSIX_VEC
	.comm	_BNX2_PCI_MSIX_CONTROL,4,2      ; @BNX2_PCI_MSIX_CONTROL
	.comm	_BNX2_MAX_MSIX_HW_VEC,8,3       ; @BNX2_MAX_MSIX_HW_VEC
	.comm	_BNX2_PCI_MSIX_TBL_OFF_BIR,4,2  ; @BNX2_PCI_MSIX_TBL_OFF_BIR
	.comm	_BNX2_PCI_GRC_WINDOW2_BASE,8,3  ; @BNX2_PCI_GRC_WINDOW2_BASE
	.comm	_BNX2_PCI_MSIX_PBA_OFF_BIT,4,2  ; @BNX2_PCI_MSIX_PBA_OFF_BIT
	.comm	_BNX2_PCI_GRC_WINDOW3_BASE,8,3  ; @BNX2_PCI_GRC_WINDOW3_BASE
	.comm	_BNX2_MIN_MSIX_VEC,4,2          ; @BNX2_MIN_MSIX_VEC
	.comm	_BNX2_FLAG_USING_MSIX,4,2       ; @BNX2_FLAG_USING_MSIX
	.comm	_BNX2_FLAG_ONE_SHOT_MSI,4,2     ; @BNX2_FLAG_ONE_SHOT_MSI
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s-%d"

	.comm	_bnx2_msi_1shot,4,2             ; @bnx2_msi_1shot
	.no_dead_strip	_bnx2_enable_msix
.subsections_via_symbols
