	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bnx2x_reset_port
_bnx2x_reset_port:                      ## @bnx2x_reset_port
	.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	%rdi, %rbx
	callq	_BP_PORT
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	_bnx2x__link_reset
	movq	_NIG_REG_MASK_INTERRUPT_PORT0@GOTPCREL(%rip), %rax
	leal	(,%r15,4), %ecx
	movslq	%ecx, %r14
	movq	(%rax), %rsi
	addq	%r14, %rsi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_REG_WR
	movq	_NIG_REG_LLH0_BRB1_DRV_MASK@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	%r14, %rsi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_REG_WR
	testl	%r15d, %r15d
	jne	LBB0_1
## %bb.2:
	movq	_NIG_REG_LLH0_BRB1_NOT_MCP@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_1:
	movq	_NIG_REG_LLH1_BRB1_NOT_MCP@GOTPCREL(%rip), %rax
LBB0_3:
	movq	(%rax), %rsi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_REG_WR
	movq	_MISC_REG_AEU_MASK_ATTN_FUNC_0@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	%r14, %rsi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_REG_WR
	movl	$100, %edi
	callq	_msleep
	movq	_BRB1_REG_PORT_NUM_OCC_BLOCKS_0@GOTPCREL(%rip), %rax
	addq	(%rax), %r14
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_REG_RD
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	movq	_NETIF_MSG_IFDOWN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	leaq	L_.str(%rip), %rsi
	movq	%rax, %rdx
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DP                             ## TAILCALL
LBB0_4:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NIG_REG_MASK_INTERRUPT_PORT0,8,3 ## @NIG_REG_MASK_INTERRUPT_PORT0
	.comm	_NIG_REG_LLH0_BRB1_DRV_MASK,8,3 ## @NIG_REG_LLH0_BRB1_DRV_MASK
	.comm	_NIG_REG_LLH1_BRB1_NOT_MCP,8,3  ## @NIG_REG_LLH1_BRB1_NOT_MCP
	.comm	_NIG_REG_LLH0_BRB1_NOT_MCP,8,3  ## @NIG_REG_LLH0_BRB1_NOT_MCP
	.comm	_MISC_REG_AEU_MASK_ATTN_FUNC_0,8,3 ## @MISC_REG_AEU_MASK_ATTN_FUNC_0
	.comm	_BRB1_REG_PORT_NUM_OCC_BLOCKS_0,8,3 ## @BRB1_REG_PORT_NUM_OCC_BLOCKS_0
	.comm	_NETIF_MSG_IFDOWN,4,2           ## @NETIF_MSG_IFDOWN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"BRB1 is not empty  %d blocks are occupied\n"

	.no_dead_strip	_bnx2x_reset_port
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bnx2x_reset_port
_bnx2x_reset_port:                      ; @bnx2x_reset_port
	.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	x19, x0
	bl	_BP_PORT
	mov	x20, x0
	mov	x0, x19
	bl	_bnx2x__link_reset
Lloh0:
	adrp	x8, _NIG_REG_MASK_INTERRUPT_PORT0@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NIG_REG_MASK_INTERRUPT_PORT0@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	lsl	w9, w20, #2
	sxtw	x21, w9
	add	x1, x8, x21
	mov	x0, x19
	mov	w2, #0
	bl	_REG_WR
Lloh3:
	adrp	x8, _NIG_REG_LLH0_BRB1_DRV_MASK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _NIG_REG_LLH0_BRB1_DRV_MASK@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	add	x1, x8, x21
	mov	x0, x19
	mov	w2, #0
	bl	_REG_WR
Lloh6:
	adrp	x8, _NIG_REG_LLH1_BRB1_NOT_MCP@GOTPAGE
Lloh7:
	ldr	x8, [x8, _NIG_REG_LLH1_BRB1_NOT_MCP@GOTPAGEOFF]
Lloh8:
	adrp	x9, _NIG_REG_LLH0_BRB1_NOT_MCP@GOTPAGE
Lloh9:
	ldr	x9, [x9, _NIG_REG_LLH0_BRB1_NOT_MCP@GOTPAGEOFF]
	cmp	w20, #0
	csel	x8, x9, x8, eq
	ldr	x1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_REG_WR
Lloh10:
	adrp	x8, _MISC_REG_AEU_MASK_ATTN_FUNC_0@GOTPAGE
Lloh11:
	ldr	x8, [x8, _MISC_REG_AEU_MASK_ATTN_FUNC_0@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
	add	x1, x8, x21
	mov	x0, x19
	mov	w2, #0
	bl	_REG_WR
	mov	w0, #100
	bl	_msleep
Lloh13:
	adrp	x8, _BRB1_REG_PORT_NUM_OCC_BLOCKS_0@GOTPAGE
Lloh14:
	ldr	x8, [x8, _BRB1_REG_PORT_NUM_OCC_BLOCKS_0@GOTPAGEOFF]
Lloh15:
	ldr	x8, [x8]
	add	x1, x8, x21
	mov	x0, x19
	bl	_REG_RD
	cbz	x0, LBB0_2
; %bb.1:
	mov	x2, x0
Lloh16:
	adrp	x8, _NETIF_MSG_IFDOWN@GOTPAGE
Lloh17:
	ldr	x8, [x8, _NETIF_MSG_IFDOWN@GOTPAGEOFF]
Lloh18:
	ldr	w0, [x8]
Lloh19:
	adrp	x1, l_.str@PAGE
Lloh20:
	add	x1, x1, l_.str@PAGEOFF
	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	_DP
LBB0_2:
	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 AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_NIG_REG_MASK_INTERRUPT_PORT0,8,3 ; @NIG_REG_MASK_INTERRUPT_PORT0
	.comm	_NIG_REG_LLH0_BRB1_DRV_MASK,8,3 ; @NIG_REG_LLH0_BRB1_DRV_MASK
	.comm	_NIG_REG_LLH1_BRB1_NOT_MCP,8,3  ; @NIG_REG_LLH1_BRB1_NOT_MCP
	.comm	_NIG_REG_LLH0_BRB1_NOT_MCP,8,3  ; @NIG_REG_LLH0_BRB1_NOT_MCP
	.comm	_MISC_REG_AEU_MASK_ATTN_FUNC_0,8,3 ; @MISC_REG_AEU_MASK_ATTN_FUNC_0
	.comm	_BRB1_REG_PORT_NUM_OCC_BLOCKS_0,8,3 ; @BRB1_REG_PORT_NUM_OCC_BLOCKS_0
	.comm	_NETIF_MSG_IFDOWN,4,2           ; @NETIF_MSG_IFDOWN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"BRB1 is not empty  %d blocks are occupied\n"

	.no_dead_strip	_bnx2x_reset_port
.subsections_via_symbols
