	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bnx2x_link_update              ## -- Begin function bnx2x_link_update
	.p2align	4, 0x90
_bnx2x_link_update:                     ## @bnx2x_link_update
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r12
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	40(%rdi), %r15
	movq	_MAX_PHYS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	imulq	$56, %rax, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r8
	movq	(%r12), %rax
	movq	%rax, -104(%rbp)                ## 8-byte Spill
	movq	_INT_PHY@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	movq	_PHY_HALF_OPEN_CONN_FLAG@GOTPCREL(%rip), %rax
	movq	_LINK_UPDATE_MASK@GOTPCREL(%rip), %rcx
	movsd	(%rcx), %xmm0                   ## xmm0 = mem[0],zero
	movsd	(%rax), %xmm1                   ## xmm1 = mem[0],zero
	movlhps	%xmm0, %xmm1                    ## xmm1 = xmm1[0],xmm0[0]
	movups	8(%rbx), %xmm0
	andnps	%xmm0, %xmm1
	movups	%xmm1, 8(%rbx)
	movq	8(%r12), %rax
	cmpq	%rax, %rdi
	jae	LBB0_3
## %bb.1:
	movq	_DUPLEX_FULL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	48(%rbx), %edx
	subq	%rdi, %rax
	imulq	$56, %rdi, %rsi
	addq	%r8, %rsi
	addq	$52, %rsi
	xorps	%xmm0, %xmm0
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	$0, -52(%rsi)
	movups	%xmm0, -36(%rsi)
	movl	%ecx, (%rsi)
	movups	%xmm0, -20(%rsi)
	movl	%edx, -4(%rsi)
	addq	$56, %rsi
	decq	%rax
	jne	LBB0_2
LBB0_3:
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	movq	%r8, -88(%rbp)                  ## 8-byte Spill
	movq	%rbx, -80(%rbp)                 ## 8-byte Spill
	movq	%r15, %r13
	movq	%r15, %rdi
	callq	_USES_WARPCORE
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	(%r14), %rsi
	shlq	$5, %rsi
	addq	24(%r12), %rsi
	movq	%r12, %rdi
	callq	_bnx2x_set_aer_mmd
LBB0_5:
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -56(%rbp)                 ## 4-byte Spill
	movq	_PHY_XGXS_FLAG@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	andq	8(%rax), %rbx
	movq	_NIG_REG_STATUS_INTERRUPT_PORT0@GOTPCREL(%rip), %rax
	movq	-104(%rbp), %r14                ## 8-byte Reload
	leaq	(,%r14,4), %r15
	movq	(%rax), %rsi
	addq	%r15, %rsi
	movq	%r13, %rdi
	callq	_REG_RD
	leaq	L_.str(%rip), %rsi
	movl	-56(%rbp), %edi                 ## 4-byte Reload
	movq	%r14, %rdx
	movq	%rbx, %rcx
	movq	%rax, %r8
	xorl	%eax, %eax
	callq	_DP
	movq	_NIG_REG_EMAC0_STATUS_MISC_MI_INT@GOTPCREL(%rip), %rax
	leaq	(%r14,%r14,2), %rsi
	shlq	$3, %rsi
	addq	(%rax), %rsi
	movq	%r13, %rdi
	callq	_REG_RD
	xorl	%ebx, %ebx
	testq	%rax, %rax
	setne	%bl
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -64(%rbp)                 ## 4-byte Spill
	movq	_NIG_REG_MASK_INTERRUPT_PORT0@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%r15, -96(%rbp)                 ## 8-byte Spill
	addq	%r15, %rsi
	movq	%r13, %rdi
	callq	_REG_RD
	movq	%r13, -56(%rbp)                 ## 8-byte Spill
	movq	%rax, %r15
	movq	_NIG_REG_SERDES0_STATUS_LINK_STATUS@GOTPCREL(%rip), %rax
	imulq	$60, %r14, %rsi
	addq	(%rax), %rsi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_REG_RD
	leaq	L_.str.1(%rip), %rsi
	movl	-64(%rbp), %edi                 ## 4-byte Reload
	movq	%r15, %rdx
	movq	%rbx, %rcx
	movq	%rax, %r8
	xorl	%eax, %eax
	callq	_DP
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	_NIG_REG_XGXS0_STATUS_LINK10G@GOTPCREL(%rip), %rax
	imulq	$104, %r14, %rbx
	movq	(%rax), %rsi
	addq	%rbx, %rsi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_REG_RD
	movq	%rax, %r13
	movq	_NIG_REG_XGXS0_STATUS_LINK_STATUS@GOTPCREL(%rip), %rax
	addq	(%rax), %rbx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_REG_RD
	leaq	L_.str.2(%rip), %rsi
	movl	%r15d, %edi
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	%r13, %rdx
	movq	%rax, %rcx
	xorl	%eax, %eax
	callq	_DP
	movq	%rbx, %rdi
	callq	_CHIP_IS_E3
	testl	%eax, %eax
	jne	LBB0_7
## %bb.6:
	movq	_NIG_REG_NIG_EMAC0_EN@GOTPCREL(%rip), %rax
	movq	-96(%rbp), %rsi                 ## 8-byte Reload
	addq	(%rax), %rsi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_REG_WR
LBB0_7:
	movq	_EXT_PHY1@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	cmpq	8(%r12), %r15
	jae	LBB0_8
## %bb.9:
	imulq	$56, %r15, %r14
	addq	-88(%rbp), %r14                 ## 8-byte Folded Reload
	movq	%r15, %rbx
	shlq	$5, %rbx
	xorl	%r13d, %r13d
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_10 Depth=1
	leaq	L_.str.4(%rip), %rsi
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_DP
LBB0_21:                                ##   in Loop: Header=BB0_10 Depth=1
	incq	%r15
	addq	$56, %r14
	addq	$32, %rbx
	cmpq	8(%r12), %r15
	jae	LBB0_22
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movq	24(%r12), %rdi
	movq	(%rdi,%rbx), %rcx
	testq	%rcx, %rcx
	je	LBB0_21
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	addq	%rbx, %rdi
	movq	%r12, %rsi
	movq	%r14, %rdx
	callq	*%rcx
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	testq	%rax, %rax
	je	LBB0_14
## %bb.12:                              ##   in Loop: Header=BB0_10 Depth=1
	leaq	L_.str.3(%rip), %rsi
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_DP
	testq	%r13, %r13
	je	LBB0_13
## %bb.15:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	%r12, %rdi
	callq	_bnx2x_phy_selection
                                        ## kill: def $eax killed $eax def $rax
	leal	-129(%rax), %ecx
	cmpl	$2, %ecx
	jae	LBB0_16
## %bb.18:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	_EXT_PHY1@GOTPCREL(%rip), %rax
	jmp	LBB0_19
LBB0_13:                                ##   in Loop: Header=BB0_10 Depth=1
	movl	$1, %r13d
	movq	%r15, -72(%rbp)                 ## 8-byte Spill
	jmp	LBB0_21
LBB0_16:                                ##   in Loop: Header=BB0_10 Depth=1
	cmpl	$128, %eax
	jne	LBB0_20
## %bb.17:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	_EXT_PHY2@GOTPCREL(%rip), %rax
LBB0_19:                                ##   in Loop: Header=BB0_10 Depth=1
	movq	(%rax), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	$1, %r13d
	jmp	LBB0_21
LBB0_20:                                ##   in Loop: Header=BB0_10 Depth=1
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	32(%r12), %edx
	leaq	L_.str.5(%rip), %rsi
	xorl	%eax, %eax
	callq	_DP
	xorl	%r13d, %r13d
	jmp	LBB0_21
LBB0_8:
	xorl	%r13d, %r13d
LBB0_22:
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	movq	(%rbx), %rax
	movq	%rax, -96(%rbp)                 ## 8-byte Spill
	movq	24(%r12), %rdi
	movq	_INT_PHY@GOTPCREL(%rip), %r14
	movq	(%r14), %rax
	movq	%rax, %rdx
	shlq	$5, %rdx
	movq	(%rdi,%rdx), %rcx
	testq	%rcx, %rcx
	je	LBB0_24
## %bb.23:
	addq	%rdx, %rdi
	movq	%r12, %rsi
	movq	%rbx, %rdx
	callq	*%rcx
	movq	(%r14), %rax
LBB0_24:
	movq	-72(%rbp), %r14                 ## 8-byte Reload
	cmpq	%rax, %r14
	jbe	LBB0_25
## %bb.26:
	movq	%r14, %rcx
	imulq	$56, %r14, %r14
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movq	24(%rdi,%r14), %rax
	movq	%rax, 24(%rbx)
	movq	16(%rdi,%r14), %rax
	orq	%rax, 16(%rbx)
	movq	_EXT_PHY1@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	jne	LBB0_29
## %bb.27:
	movq	24(%r12), %rax
	movq	_EXT_PHY2@GOTPCREL(%rip), %r15
	movq	(%r15), %rcx
	shlq	$5, %rcx
	cmpq	$0, 24(%rax,%rcx)
	je	LBB0_29
## %bb.28:
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.6(%rip), %rsi
	xorl	%eax, %eax
	callq	_DP
	movq	24(%r12), %rax
	movq	(%r15), %rcx
	shlq	$5, %rcx
	leaq	(%rax,%rcx), %rdi
	movq	_DISABLE_TX@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	movq	%r12, %rsi
	callq	*24(%rax,%rcx)
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
LBB0_29:
	movq	(%rdi,%r14), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movl	52(%rdi,%r14), %eax
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	movl	%eax, 52(%rbx)
	movq	24(%r12), %rcx
	movq	-72(%rbp), %rdx                 ## 8-byte Reload
	shlq	$5, %rdx
	movq	_SUPPORTED_FIBRE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_LINK_STATUS_SERDES_LINK@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	testl	%esi, 8(%rcx,%rdx)
	je	LBB0_31
## %bb.30:
	orq	16(%rbx), %rax
	jmp	LBB0_32
LBB0_25:
	xorl	%eax, %eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	jmp	LBB0_33
LBB0_31:
	notq	%rax
	andq	16(%rbx), %rax
LBB0_32:
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movq	%rax, 16(%rbx)
	movl	48(%rdi,%r14), %eax
	movl	%eax, 48(%rbx)
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.7(%rip), %rsi
	movq	-72(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdx
	xorl	%eax, %eax
	callq	_DP
LBB0_33:
	movq	_EXT_PHY1@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	8(%r12), %rcx
	cmpq	%rcx, %rax
	jae	LBB0_38
## %bb.34:
	movq	24(%r12), %rsi
	movq	_FLAGS_REARM_LATCH_SIGNAL@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	movq	%rax, %rdi
	shlq	$5, %rdi
	addq	%rdi, %rsi
	addq	$12, %rsi
	.p2align	4, 0x90
LBB0_35:                                ## =>This Inner Loop Header: Depth=1
	testl	%edx, (%rsi)
	jne	LBB0_36
## %bb.37:                              ##   in Loop: Header=BB0_35 Depth=1
	incq	%rax
	addq	$32, %rsi
	cmpq	%rax, %rcx
	jne	LBB0_35
	jmp	LBB0_38
LBB0_36:
	xorl	%edx, %edx
	cmpq	%rax, %r14
	sete	%dl
	movq	%r15, %rdi
	movq	-104(%rbp), %rsi                ## 8-byte Reload
	callq	_bnx2x_rearm_latch_signal
LBB0_38:
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	16(%rbx), %rcx
	movq	24(%rbx), %rdx
	leaq	L_.str.8(%rip), %rsi
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	xorl	%eax, %eax
	callq	_DP
	cmpl	$0, 32(%rbx)
	je	LBB0_46
## %bb.39:
	movq	%r12, %rdi
	callq	_SINGLE_MEDIA_DIRECT
	movq	(%rbx), %rdx
	testq	%rax, %rax
	jne	LBB0_40
## %bb.43:
	testq	%r13, %r13
	je	LBB0_40
## %bb.44:
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	%rcx, %rax
	cmpq	%rdx, %rcx
	je	LBB0_41
## %bb.45:
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.9(%rip), %rsi
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_DP
	movl	$0, 32(%rbx)
	jmp	LBB0_46
LBB0_40:
	movq	%rdx, %rax
LBB0_41:
	cmpq	%rax, -96(%rbp)                 ## 8-byte Folded Reload
	je	LBB0_46
## %bb.42:
	movq	_NIG_REG_EGRESS_DRAIN0_MODE@GOTPCREL(%rip), %rax
	movq	(%r12), %rsi
	shlq	$2, %rsi
	addq	(%rax), %rsi
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_REG_WR
	movl	$1000, %edi                     ## imm = 0x3E8
	movl	$2000, %esi                     ## imm = 0x7D0
	callq	_usleep_range
LBB0_46:
	movq	(%rbx), %rax
	movq	_SPEED_10000@GOTPCREL(%rip), %rcx
	xorl	%r14d, %r14d
	cmpq	(%rcx), %rax
	setae	%r14b
	movq	%r12, %rdi
	movq	%rbx, %rsi
	movq	%r14, %rdx
	callq	_bnx2x_link_int_ack
	movq	%r12, %rdi
	callq	_SINGLE_MEDIA_DIRECT
	testq	%rax, %rax
	je	LBB0_47
LBB0_55:
	movq	%rbx, %rax
	xorl	%ebx, %ebx
	cmpl	$0, 32(%rax)
	je	LBB0_59
## %bb.56:
	testq	%r13, %r13
	jne	LBB0_58
## %bb.57:
	movq	%r12, %rdi
	callq	_SINGLE_MEDIA_DIRECT
	testq	%rax, %rax
	jne	LBB0_58
	jmp	LBB0_59
LBB0_47:
	movq	_NETIF_MSG_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	32(%rbx), %ecx
	movq	24(%r12), %rax
	movq	_EXT_PHY1@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	shlq	$5, %rdx
	movslq	12(%rax,%rdx), %r8
	movq	_FLAGS_INIT_XGXS_FIRST@GOTPCREL(%rip), %rbx
	andq	(%rbx), %r8
	leaq	L_.str.10(%rip), %rsi
	movq	%r13, %rdx
	xorl	%eax, %eax
	callq	_DP
	movq	24(%r12), %rdi
	movq	_EXT_PHY1@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	shlq	$5, %rax
	movslq	12(%rdi,%rax), %rax
	testq	%rax, (%rbx)
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	jne	LBB0_55
## %bb.48:
	testq	%r13, %r13
	je	LBB0_55
## %bb.49:
	cmpl	$0, 32(%rbx)
	je	LBB0_50
LBB0_58:
	imulq	$56, -72(%rbp), %rax            ## 8-byte Folded Reload
	xorl	%ebx, %ebx
	movq	-88(%rbp), %rcx                 ## 8-byte Reload
	cmpq	$0, 40(%rcx,%rax)
	sete	%bl
LBB0_59:
	movq	-80(%rbp), %rsi                 ## 8-byte Reload
	movl	%ebx, 36(%rsi)
	movq	_FEATURE_CONFIG_PFC_ENABLED@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_LINK_STATUS_PFC_ENABLED@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	testl	%ecx, 16(%r12)
	je	LBB0_61
## %bb.60:
	orq	16(%rsi), %rax
	jmp	LBB0_62
LBB0_61:
	notq	%rax
	andq	16(%rsi), %rax
LBB0_62:
	movq	%rax, 16(%rsi)
	movq	%r12, %rdi
	testl	%ebx, %ebx
	je	LBB0_64
## %bb.63:
	movq	%r14, %rdx
	callq	_bnx2x_update_link_up
	jmp	LBB0_65
LBB0_64:
	callq	_bnx2x_update_link_down
LBB0_65:
	movl	%eax, %ebx
	movq	_FEATURE_CONFIG_BC_SUPPORTS_AFEX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 16(%r12)
	je	LBB0_67
## %bb.66:
	movq	_DRV_MSG_CODE_LINK_STATUS_CHANGED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_bnx2x_fw_command
LBB0_67:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_69
## %bb.68:
	movl	%ebx, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_50:
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	movq	-64(%rbp), %rdx                 ## 8-byte Reload
	movq	%rdx, (%rbx)
	movq	_SPEED_1000@GOTPCREL(%rip), %rcx
	movq	_PHY_SGMII_FLAG@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	(%rcx), %rdx
	jae	LBB0_52
## %bb.51:
	orq	8(%rbx), %rax
	jmp	LBB0_53
LBB0_52:
	notq	%rax
	andq	8(%rbx), %rax
LBB0_53:
	movq	%rax, 8(%rbx)
	movq	_INT_PHY@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	shlq	$5, %rcx
	movq	16(%rdi,%rcx), %rax
	testq	%rax, %rax
	je	LBB0_55
## %bb.54:
	addq	%rcx, %rdi
	movq	%r12, %rsi
	movq	%rbx, %rdx
	callq	*%rax
	jmp	LBB0_55
LBB0_69:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_PHYS,4,2                   ## @MAX_PHYS
	.comm	_INT_PHY,8,3                    ## @INT_PHY
	.comm	_PHY_HALF_OPEN_CONN_FLAG,8,3    ## @PHY_HALF_OPEN_CONN_FLAG
	.comm	_LINK_UPDATE_MASK,8,3           ## @LINK_UPDATE_MASK
	.comm	_DUPLEX_FULL,4,2                ## @DUPLEX_FULL
	.comm	_NETIF_MSG_LINK,4,2             ## @NETIF_MSG_LINK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"port %x, XGXS?%x, int_status 0x%x\n"

	.comm	_PHY_XGXS_FLAG,8,3              ## @PHY_XGXS_FLAG
	.comm	_NIG_REG_STATUS_INTERRUPT_PORT0,8,3 ## @NIG_REG_STATUS_INTERRUPT_PORT0
	.comm	_NIG_REG_EMAC0_STATUS_MISC_MI_INT,8,3 ## @NIG_REG_EMAC0_STATUS_MISC_MI_INT
L_.str.1:                               ## @.str.1
	.asciz	"int_mask 0x%x MI_INT %x, SERDES_LINK %x\n"

	.comm	_NIG_REG_MASK_INTERRUPT_PORT0,8,3 ## @NIG_REG_MASK_INTERRUPT_PORT0
	.comm	_NIG_REG_SERDES0_STATUS_LINK_STATUS,8,3 ## @NIG_REG_SERDES0_STATUS_LINK_STATUS
L_.str.2:                               ## @.str.2
	.asciz	" 10G %x, XGXS_LINK %x\n"

	.comm	_NIG_REG_XGXS0_STATUS_LINK10G,8,3 ## @NIG_REG_XGXS0_STATUS_LINK10G
	.comm	_NIG_REG_XGXS0_STATUS_LINK_STATUS,8,3 ## @NIG_REG_XGXS0_STATUS_LINK_STATUS
	.comm	_NIG_REG_NIG_EMAC0_EN,8,3       ## @NIG_REG_NIG_EMAC0_EN
	.comm	_EXT_PHY1,8,3                   ## @EXT_PHY1
L_.str.3:                               ## @.str.3
	.asciz	"phy in index %d link is up\n"

L_.str.4:                               ## @.str.4
	.asciz	"phy in index %d link is down\n"

	.comm	_EXT_PHY2,8,3                   ## @EXT_PHY2
L_.str.5:                               ## @.str.5
	.asciz	"Invalid link indicationmpc=0x%x. DISABLING LINK !!!\n"

L_.str.6:                               ## @.str.6
	.asciz	"Disabling TX on EXT_PHY2\n"

	.comm	_DISABLE_TX,4,2                 ## @DISABLE_TX
	.comm	_SUPPORTED_FIBRE,4,2            ## @SUPPORTED_FIBRE
	.comm	_LINK_STATUS_SERDES_LINK,8,3    ## @LINK_STATUS_SERDES_LINK
L_.str.7:                               ## @.str.7
	.asciz	"Active external phy selected: %x\n"

	.comm	_FLAGS_REARM_LATCH_SIGNAL,4,2   ## @FLAGS_REARM_LATCH_SIGNAL
L_.str.8:                               ## @.str.8
	.asciz	"vars->flow_ctrl = 0x%x, vars->link_status = 0x%x, ext_phy_line_speed = %d\n"

L_.str.9:                               ## @.str.9
	.asciz	"Internal link speed %d is different than the external link speed %d\n"

	.comm	_NIG_REG_EGRESS_DRAIN0_MODE,8,3 ## @NIG_REG_EGRESS_DRAIN0_MODE
	.comm	_SPEED_10000,8,3                ## @SPEED_10000
L_.str.10:                              ## @.str.10
	.asciz	"ext_phy_link_up = %d, int_link_up = %d, init_preceding = %d\n"

	.comm	_FLAGS_INIT_XGXS_FIRST,8,3      ## @FLAGS_INIT_XGXS_FIRST
	.comm	_SPEED_1000,8,3                 ## @SPEED_1000
	.comm	_PHY_SGMII_FLAG,8,3             ## @PHY_SGMII_FLAG
	.comm	_FEATURE_CONFIG_PFC_ENABLED,4,2 ## @FEATURE_CONFIG_PFC_ENABLED
	.comm	_LINK_STATUS_PFC_ENABLED,8,3    ## @LINK_STATUS_PFC_ENABLED
	.comm	_FEATURE_CONFIG_BC_SUPPORTS_AFEX,4,2 ## @FEATURE_CONFIG_BC_SUPPORTS_AFEX
	.comm	_DRV_MSG_CODE_LINK_STATUS_CHANGED,4,2 ## @DRV_MSG_CODE_LINK_STATUS_CHANGED
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bnx2x_link_update              ; -- Begin function bnx2x_link_update
	.p2align	2
_bnx2x_link_update:                     ; @bnx2x_link_update
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	sub	sp, sp, #32
	mov	x21, x1
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _MAX_PHYS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_PHYS@GOTPAGEOFF]
	ldr	x27, [x0, #40]
Lloh5:
	ldr	w8, [x8]
	mov	w9, #56
	mul	x9, x8, x9
	add	x8, x9, #15
	and	x8, x8, #0x7ffffffff0
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	sub	x22, x9, x8
	mov	sp, x22
Lloh8:
	adrp	x23, _INT_PHY@GOTPAGE
Lloh9:
	ldr	x23, [x23, _INT_PHY@GOTPAGEOFF]
Lloh10:
	adrp	x8, _PHY_HALF_OPEN_CONN_FLAG@GOTPAGE
Lloh11:
	ldr	x8, [x8, _PHY_HALF_OPEN_CONN_FLAG@GOTPAGEOFF]
	ldr	x28, [x0]
Lloh12:
	ldr	d0, [x8]
Lloh13:
	adrp	x8, _LINK_UPDATE_MASK@GOTPAGE
Lloh14:
	ldr	x8, [x8, _LINK_UPDATE_MASK@GOTPAGEOFF]
	ld1.d	{ v0 }[1], [x8]
	ldr	x19, [x23]
	ldur	q1, [x1, #8]
	bic.16b	v0, v1, v0
	stur	q0, [x1, #8]
	ldr	x10, [x0, #8]
	cmp	x19, x10
	b.hs	LBB0_3
; %bb.1:
Lloh15:
	adrp	x8, _DUPLEX_FULL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _DUPLEX_FULL@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	ldr	w9, [x21, #48]
	sub	x10, x10, x19
	mov	w11, #56
	madd	x11, x19, x11, x22
	add	x11, x11, #52
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	stur	xzr, [x11, #-52]
	stur	xzr, [x11, #-28]
	stur	xzr, [x11, #-36]
	stp	w9, w8, [x11, #-4]
	stur	xzr, [x11, #-12]
	stur	xzr, [x11, #-20]
	add	x11, x11, #56
	subs	x10, x10, #1
	b.ne	LBB0_2
LBB0_3:
	mov	x0, x27
	bl	_USES_WARPCORE
	cbz	x0, LBB0_5
; %bb.4:
	ldr	x8, [x20, #24]
	ldr	x9, [x23]
	add	x1, x8, x9, lsl #5
	mov	x0, x20
	bl	_bnx2x_set_aer_mmd
LBB0_5:
	stur	x22, [x29, #-96]                ; 8-byte Folded Spill
Lloh18:
	adrp	x26, _NETIF_MSG_LINK@GOTPAGE
Lloh19:
	ldr	x26, [x26, _NETIF_MSG_LINK@GOTPAGEOFF]
	ldr	w23, [x26]
	ldr	x8, [x21, #8]
Lloh20:
	adrp	x9, _PHY_XGXS_FLAG@GOTPAGE
Lloh21:
	ldr	x9, [x9, _PHY_XGXS_FLAG@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
	and	x24, x9, x8
Lloh23:
	adrp	x8, _NIG_REG_STATUS_INTERRUPT_PORT0@GOTPAGE
Lloh24:
	ldr	x8, [x8, _NIG_REG_STATUS_INTERRUPT_PORT0@GOTPAGEOFF]
Lloh25:
	ldr	x8, [x8]
	lsl	x22, x28, #2
	add	x1, x8, x22
	mov	x0, x27
	bl	_REG_RD
	sub	sp, sp, #32
	stp	x24, x0, [sp, #8]
	str	x28, [sp]
Lloh26:
	adrp	x1, l_.str@PAGE
Lloh27:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x23
	bl	_DP
	add	sp, sp, #32
Lloh28:
	adrp	x8, _NIG_REG_EMAC0_STATUS_MISC_MI_INT@GOTPAGE
Lloh29:
	ldr	x8, [x8, _NIG_REG_EMAC0_STATUS_MISC_MI_INT@GOTPAGEOFF]
Lloh30:
	ldr	x8, [x8]
	mov	w9, #24
	madd	x1, x28, x9, x8
	mov	x0, x27
	bl	_REG_RD
	cmp	x0, #0
	cset	w25, ne
	ldr	w23, [x26]
Lloh31:
	adrp	x8, _NIG_REG_MASK_INTERRUPT_PORT0@GOTPAGE
Lloh32:
	ldr	x8, [x8, _NIG_REG_MASK_INTERRUPT_PORT0@GOTPAGEOFF]
Lloh33:
	ldr	x8, [x8]
	add	x1, x8, x22
	mov	x0, x27
	bl	_REG_RD
	mov	x24, x0
Lloh34:
	adrp	x8, _NIG_REG_SERDES0_STATUS_LINK_STATUS@GOTPAGE
Lloh35:
	ldr	x8, [x8, _NIG_REG_SERDES0_STATUS_LINK_STATUS@GOTPAGEOFF]
Lloh36:
	ldr	x8, [x8]
	mov	w9, #60
	madd	x1, x28, x9, x8
	mov	x0, x27
	bl	_REG_RD
	sub	sp, sp, #32
	stp	x25, x0, [sp, #8]
	str	x24, [sp]
Lloh37:
	adrp	x1, l_.str.1@PAGE
Lloh38:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x23
	bl	_DP
	add	sp, sp, #32
	ldr	w23, [x26]
Lloh39:
	adrp	x8, _NIG_REG_XGXS0_STATUS_LINK10G@GOTPAGE
Lloh40:
	ldr	x8, [x8, _NIG_REG_XGXS0_STATUS_LINK10G@GOTPAGEOFF]
Lloh41:
	ldr	x8, [x8]
	mov	w9, #104
	stur	x28, [x29, #-112]               ; 8-byte Folded Spill
	mul	x25, x28, x9
	add	x1, x8, x25
	mov	x0, x27
	bl	_REG_RD
	mov	x24, x0
Lloh42:
	adrp	x8, _NIG_REG_XGXS0_STATUS_LINK_STATUS@GOTPAGE
Lloh43:
	ldr	x8, [x8, _NIG_REG_XGXS0_STATUS_LINK_STATUS@GOTPAGEOFF]
Lloh44:
	ldr	x8, [x8]
	add	x1, x8, x25
	mov	x0, x27
	bl	_REG_RD
	stp	x24, x0, [sp, #-16]!
Lloh45:
	adrp	x1, l_.str.2@PAGE
Lloh46:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x23
	bl	_DP
	add	sp, sp, #16
	mov	x0, x27
	bl	_CHIP_IS_E3
	cbnz	w0, LBB0_7
; %bb.6:
Lloh47:
	adrp	x8, _NIG_REG_NIG_EMAC0_EN@GOTPAGE
Lloh48:
	ldr	x8, [x8, _NIG_REG_NIG_EMAC0_EN@GOTPAGEOFF]
Lloh49:
	ldr	x8, [x8]
	add	x1, x8, x22
	mov	x0, x27
	mov	w2, #0
	bl	_REG_WR
LBB0_7:
	stur	x27, [x29, #-104]               ; 8-byte Folded Spill
Lloh50:
	adrp	x8, _EXT_PHY1@GOTPAGE
Lloh51:
	ldr	x8, [x8, _EXT_PHY1@GOTPAGEOFF]
Lloh52:
	ldr	x28, [x8]
	ldr	x8, [x20, #8]
	cmp	x28, x8
	b.hs	LBB0_21
; %bb.8:
	mov	x27, #0
	mov	w8, #56
	ldur	x9, [x29, #-96]                 ; 8-byte Folded Reload
	madd	x23, x28, x8, x9
	lsl	x22, x28, #5
Lloh53:
	adrp	x24, l_.str.4@PAGE
Lloh54:
	add	x24, x24, l_.str.4@PAGEOFF
Lloh55:
	adrp	x25, l_.str.3@PAGE
Lloh56:
	add	x25, x25, l_.str.3@PAGEOFF
	b	LBB0_11
LBB0_9:                                 ;   in Loop: Header=BB0_11 Depth=1
	str	x28, [sp]
	mov	x1, x24
	bl	_DP
	add	sp, sp, #16
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x28, x28, #1
	ldr	x8, [x20, #8]
	add	x23, x23, #56
	add	x22, x22, #32
	cmp	x28, x8
	b.hs	LBB0_22
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x20, #24]
	add	x0, x8, x22
	ldr	x8, [x0]
	cbz	x8, LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	mov	x1, x20
	mov	x2, x23
	blr	x8
	mov	x8, x0
	ldr	w0, [x26]
	sub	sp, sp, #16
	cbz	x8, LBB0_9
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=1
	str	x28, [sp]
	mov	x1, x25
	bl	_DP
	add	sp, sp, #16
	cbz	x27, LBB0_16
; %bb.14:                               ;   in Loop: Header=BB0_11 Depth=1
	mov	x0, x20
	bl	_bnx2x_phy_selection
	sub	w8, w0, #129
	cmp	w8, #2
	b.hs	LBB0_17
; %bb.15:                               ;   in Loop: Header=BB0_11 Depth=1
Lloh57:
	adrp	x8, _EXT_PHY1@GOTPAGE
Lloh58:
	ldr	x8, [x8, _EXT_PHY1@GOTPAGEOFF]
	b	LBB0_19
LBB0_16:                                ;   in Loop: Header=BB0_11 Depth=1
	mov	w27, #1
	mov	x19, x28
	b	LBB0_10
LBB0_17:                                ;   in Loop: Header=BB0_11 Depth=1
	cmp	w0, #128
	b.ne	LBB0_20
; %bb.18:                               ;   in Loop: Header=BB0_11 Depth=1
Lloh59:
	adrp	x8, _EXT_PHY2@GOTPAGE
Lloh60:
	ldr	x8, [x8, _EXT_PHY2@GOTPAGEOFF]
LBB0_19:                                ;   in Loop: Header=BB0_11 Depth=1
	ldr	x19, [x8]
	mov	w27, #1
	b	LBB0_10
LBB0_20:                                ;   in Loop: Header=BB0_11 Depth=1
	ldr	w0, [x26]
	ldr	w8, [x20, #32]
	str	x8, [sp, #-16]!
Lloh61:
	adrp	x1, l_.str.5@PAGE
Lloh62:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_DP
	add	sp, sp, #16
	mov	x27, #0
	b	LBB0_10
LBB0_21:
	mov	x27, #0
LBB0_22:
	ldr	x24, [x21]
	ldr	x9, [x20, #24]
Lloh63:
	adrp	x22, _INT_PHY@GOTPAGE
Lloh64:
	ldr	x22, [x22, _INT_PHY@GOTPAGEOFF]
	ldr	x8, [x22]
	add	x0, x9, x8, lsl #5
	ldr	x9, [x0]
	cbz	x9, LBB0_24
; %bb.23:
	mov	x1, x20
	mov	x2, x21
	blr	x9
	ldr	x8, [x22]
LBB0_24:
	ldp	x25, x28, [x29, #-104]          ; 16-byte Folded Reload
	cmp	x19, x8
	b.ls	LBB0_30
; %bb.25:
	mov	w8, #56
	mul	x8, x19, x8
	add	x8, x28, x8
	ldp	x8, x9, [x8, #16]
	ldr	x10, [x21, #16]
	orr	x8, x10, x8
	stp	x8, x9, [x21, #16]
Lloh65:
	adrp	x8, _EXT_PHY1@GOTPAGE
Lloh66:
	ldr	x8, [x8, _EXT_PHY1@GOTPAGEOFF]
Lloh67:
	ldr	x8, [x8]
	cmp	x19, x8
	b.ne	LBB0_28
; %bb.26:
	ldr	x8, [x20, #24]
Lloh68:
	adrp	x22, _EXT_PHY2@GOTPAGE
Lloh69:
	ldr	x22, [x22, _EXT_PHY2@GOTPAGEOFF]
	ldr	x9, [x22]
	add	x8, x8, x9, lsl #5
	ldr	x8, [x8, #24]
	cbz	x8, LBB0_28
; %bb.27:
	ldr	w0, [x26]
Lloh70:
	adrp	x1, l_.str.6@PAGE
Lloh71:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_DP
	ldr	x8, [x20, #24]
	ldr	x9, [x22]
	add	x0, x8, x9, lsl #5
	ldr	x8, [x0, #24]
Lloh72:
	adrp	x9, _DISABLE_TX@GOTPAGE
Lloh73:
	ldr	x9, [x9, _DISABLE_TX@GOTPAGEOFF]
Lloh74:
	ldr	w2, [x9]
	mov	x1, x20
	blr	x8
LBB0_28:
	mov	w8, #56
	mul	x8, x19, x8
	add	x8, x28, x8
	ldr	x23, [x8]
	ldr	w8, [x8, #52]
	str	w8, [x21, #52]
	ldr	x8, [x20, #24]
	add	x8, x8, x19, lsl #5
Lloh75:
	adrp	x9, _SUPPORTED_FIBRE@GOTPAGE
Lloh76:
	ldr	x9, [x9, _SUPPORTED_FIBRE@GOTPAGEOFF]
	ldr	w10, [x8, #8]
Lloh77:
	ldr	w9, [x9]
Lloh78:
	adrp	x8, _LINK_STATUS_SERDES_LINK@GOTPAGE
Lloh79:
	ldr	x8, [x8, _LINK_STATUS_SERDES_LINK@GOTPAGEOFF]
Lloh80:
	ldr	x8, [x8]
	tst	w9, w10
	b.eq	LBB0_31
; %bb.29:
	ldr	x9, [x21, #16]
	orr	x8, x9, x8
	b	LBB0_32
LBB0_30:
	mov	x23, #0
	b	LBB0_33
LBB0_31:
	ldr	x9, [x21, #16]
	bic	x8, x9, x8
LBB0_32:
	str	x8, [x21, #16]
	mov	w8, #56
	mul	x8, x19, x8
	add	x8, x28, x8
	ldr	w8, [x8, #48]
	str	w8, [x21, #48]
	ldr	w0, [x26]
	str	x19, [sp, #-16]!
Lloh81:
	adrp	x1, l_.str.7@PAGE
Lloh82:
	add	x1, x1, l_.str.7@PAGEOFF
	bl	_DP
	add	sp, sp, #16
LBB0_33:
Lloh83:
	adrp	x8, _EXT_PHY1@GOTPAGE
Lloh84:
	ldr	x8, [x8, _EXT_PHY1@GOTPAGEOFF]
Lloh85:
	ldr	x11, [x8]
	ldr	x10, [x20, #8]
	cmp	x11, x10
	b.hs	LBB0_38
; %bb.34:
Lloh86:
	adrp	x8, _FLAGS_REARM_LATCH_SIGNAL@GOTPAGE
Lloh87:
	ldr	x8, [x8, _FLAGS_REARM_LATCH_SIGNAL@GOTPAGEOFF]
	ldr	x12, [x20, #24]
Lloh88:
	ldr	w9, [x8]
	sub	x8, x19, x11
	sub	x10, x10, x11
	add	x11, x12, x11, lsl #5
	add	x11, x11, #12
LBB0_35:                                ; =>This Inner Loop Header: Depth=1
	ldr	w12, [x11]
	tst	w9, w12
	b.ne	LBB0_37
; %bb.36:                               ;   in Loop: Header=BB0_35 Depth=1
	sub	x8, x8, #1
	add	x11, x11, #32
	subs	x10, x10, #1
	b.ne	LBB0_35
	b	LBB0_38
LBB0_37:
	cmp	x8, #0
	cset	w2, eq
	mov	x0, x25
	ldur	x1, [x29, #-112]                ; 8-byte Folded Reload
	bl	_bnx2x_rearm_latch_signal
LBB0_38:
	ldr	w0, [x26]
	ldp	x9, x8, [x21, #16]
	sub	sp, sp, #32
	stp	x9, x23, [sp, #8]
	str	x8, [sp]
Lloh89:
	adrp	x1, l_.str.8@PAGE
Lloh90:
	add	x1, x1, l_.str.8@PAGEOFF
	bl	_DP
	add	sp, sp, #32
	ldr	w8, [x21, #32]
	cbz	w8, LBB0_46
; %bb.39:
	mov	x0, x20
	bl	_SINGLE_MEDIA_DIRECT
	ldr	x8, [x21]
	cbnz	x0, LBB0_43
; %bb.40:
	cbz	x27, LBB0_43
; %bb.41:
	mov	x9, x23
	cmp	x23, x8
	b.eq	LBB0_44
; %bb.42:
	ldr	w0, [x26]
	stp	x8, x23, [sp, #-16]!
Lloh91:
	adrp	x1, l_.str.9@PAGE
Lloh92:
	add	x1, x1, l_.str.9@PAGEOFF
	bl	_DP
	add	sp, sp, #16
	str	wzr, [x21, #32]
	b	LBB0_46
LBB0_43:
	mov	x9, x8
LBB0_44:
	cmp	x24, x9
	b.eq	LBB0_46
; %bb.45:
Lloh93:
	adrp	x8, _NIG_REG_EGRESS_DRAIN0_MODE@GOTPAGE
Lloh94:
	ldr	x8, [x8, _NIG_REG_EGRESS_DRAIN0_MODE@GOTPAGEOFF]
Lloh95:
	ldr	x8, [x8]
	ldr	x9, [x20]
	add	x1, x8, x9, lsl #2
	mov	x0, x25
	mov	w2, #0
	bl	_REG_WR
	mov	w0, #1000
	mov	w1, #2000
	bl	_usleep_range
LBB0_46:
	ldr	x8, [x21]
Lloh96:
	adrp	x9, _SPEED_10000@GOTPAGE
Lloh97:
	ldr	x9, [x9, _SPEED_10000@GOTPAGEOFF]
Lloh98:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w22, hs
	mov	x0, x20
	mov	x1, x21
	mov	x2, x22
	bl	_bnx2x_link_int_ack
	mov	x0, x20
	bl	_SINGLE_MEDIA_DIRECT
	cbnz	x0, LBB0_48
; %bb.47:
	ldr	w0, [x26]
	ldr	x8, [x20, #24]
Lloh99:
	adrp	x26, _EXT_PHY1@GOTPAGE
Lloh100:
	ldr	x26, [x26, _EXT_PHY1@GOTPAGEOFF]
	ldr	x9, [x26]
	add	x8, x8, x9, lsl #5
	ldrsw	x8, [x8, #12]
Lloh101:
	adrp	x24, _FLAGS_INIT_XGXS_FIRST@GOTPAGE
Lloh102:
	ldr	x24, [x24, _FLAGS_INIT_XGXS_FIRST@GOTPAGEOFF]
	ldr	x9, [x24]
	and	x8, x9, x8
	ldr	w9, [x21, #32]
	sub	sp, sp, #32
	stp	x9, x8, [sp, #8]
	str	x27, [sp]
Lloh103:
	adrp	x1, l_.str.10@PAGE
Lloh104:
	add	x1, x1, l_.str.10@PAGEOFF
	bl	_DP
	add	sp, sp, #32
	ldr	x8, [x20, #24]
	ldr	x9, [x26]
	add	x9, x8, x9, lsl #5
	ldrsw	x9, [x9, #12]
	ldr	x10, [x24]
	and	x9, x10, x9
	cmp	x9, #0
	ccmp	x27, #0, #4, eq
	b.ne	LBB0_52
LBB0_48:
	ldr	w8, [x21, #32]
	cbz	w8, LBB0_54
; %bb.49:
	cbnz	x27, LBB0_53
; %bb.50:
	mov	x0, x20
	bl	_SINGLE_MEDIA_DIRECT
	cbnz	x0, LBB0_53
; %bb.51:
	mov	w8, #0
	b	LBB0_54
LBB0_52:
	ldr	w9, [x21, #32]
	cbz	w9, LBB0_64
LBB0_53:
	mov	w8, #56
	mul	x8, x19, x8
	add	x8, x28, x8
	ldr	x8, [x8, #40]
	cmp	x8, #0
	cset	w8, eq
LBB0_54:
	str	w8, [x21, #36]
Lloh105:
	adrp	x9, _FEATURE_CONFIG_PFC_ENABLED@GOTPAGE
Lloh106:
	ldr	x9, [x9, _FEATURE_CONFIG_PFC_ENABLED@GOTPAGEOFF]
	ldr	w10, [x20, #16]
Lloh107:
	ldr	w11, [x9]
Lloh108:
	adrp	x9, _LINK_STATUS_PFC_ENABLED@GOTPAGE
Lloh109:
	ldr	x9, [x9, _LINK_STATUS_PFC_ENABLED@GOTPAGEOFF]
Lloh110:
	ldr	x9, [x9]
	tst	w11, w10
	b.eq	LBB0_56
; %bb.55:
	ldr	x10, [x21, #16]
	orr	x9, x10, x9
	b	LBB0_57
LBB0_56:
	ldr	x10, [x21, #16]
	bic	x9, x10, x9
LBB0_57:
	str	x9, [x21, #16]
	mov	x0, x20
	mov	x1, x21
	cbz	w8, LBB0_59
; %bb.58:
	mov	x2, x22
	bl	_bnx2x_update_link_up
	b	LBB0_60
LBB0_59:
	bl	_bnx2x_update_link_down
LBB0_60:
	mov	x21, x0
	ldr	w8, [x20, #16]
Lloh111:
	adrp	x9, _FEATURE_CONFIG_BC_SUPPORTS_AFEX@GOTPAGE
Lloh112:
	ldr	x9, [x9, _FEATURE_CONFIG_BC_SUPPORTS_AFEX@GOTPAGEOFF]
Lloh113:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_62
; %bb.61:
Lloh114:
	adrp	x8, _DRV_MSG_CODE_LINK_STATUS_CHANGED@GOTPAGE
Lloh115:
	ldr	x8, [x8, _DRV_MSG_CODE_LINK_STATUS_CHANGED@GOTPAGEOFF]
Lloh116:
	ldr	w1, [x8]
	mov	x0, x25
	mov	w2, #0
	bl	_bnx2x_fw_command
LBB0_62:
	ldur	x8, [x29, #-88]
Lloh117:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh118:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh119:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_69
; %bb.63:
	mov	x0, x21
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_64:
Lloh120:
	adrp	x9, _SPEED_1000@GOTPAGE
Lloh121:
	ldr	x9, [x9, _SPEED_1000@GOTPAGEOFF]
	str	x23, [x21]
Lloh122:
	ldr	x10, [x9]
Lloh123:
	adrp	x9, _PHY_SGMII_FLAG@GOTPAGE
Lloh124:
	ldr	x9, [x9, _PHY_SGMII_FLAG@GOTPAGEOFF]
Lloh125:
	ldr	x9, [x9]
	cmp	x23, x10
	b.hs	LBB0_66
; %bb.65:
	ldr	x10, [x21, #8]
	orr	x9, x10, x9
	b	LBB0_67
LBB0_66:
	ldr	x10, [x21, #8]
	bic	x9, x10, x9
LBB0_67:
Lloh126:
	adrp	x10, _INT_PHY@GOTPAGE
Lloh127:
	ldr	x10, [x10, _INT_PHY@GOTPAGEOFF]
	str	x9, [x21, #8]
Lloh128:
	ldr	x9, [x10]
	add	x0, x8, x9, lsl #5
	ldr	x8, [x0, #16]
	cbz	x8, LBB0_48
; %bb.68:
	mov	x1, x20
	mov	x2, x21
	blr	x8
	b	LBB0_48
LBB0_69:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpAdd	Lloh55, Lloh56
	.loh AdrpAdd	Lloh53, Lloh54
	.loh AdrpLdrGot	Lloh57, Lloh58
	.loh AdrpLdrGot	Lloh59, Lloh60
	.loh AdrpAdd	Lloh61, Lloh62
	.loh AdrpLdrGot	Lloh63, Lloh64
	.loh AdrpLdrGotLdr	Lloh65, Lloh66, Lloh67
	.loh AdrpLdrGot	Lloh68, Lloh69
	.loh AdrpLdrGotLdr	Lloh72, Lloh73, Lloh74
	.loh AdrpAdd	Lloh70, Lloh71
	.loh AdrpLdrGotLdr	Lloh78, Lloh79, Lloh80
	.loh AdrpLdrGotLdr	Lloh75, Lloh76, Lloh77
	.loh AdrpAdd	Lloh81, Lloh82
	.loh AdrpLdrGotLdr	Lloh83, Lloh84, Lloh85
	.loh AdrpLdrGotLdr	Lloh86, Lloh87, Lloh88
	.loh AdrpAdd	Lloh89, Lloh90
	.loh AdrpAdd	Lloh91, Lloh92
	.loh AdrpLdrGotLdr	Lloh93, Lloh94, Lloh95
	.loh AdrpLdrGotLdr	Lloh96, Lloh97, Lloh98
	.loh AdrpAdd	Lloh103, Lloh104
	.loh AdrpLdrGot	Lloh101, Lloh102
	.loh AdrpLdrGot	Lloh99, Lloh100
	.loh AdrpLdrGotLdr	Lloh108, Lloh109, Lloh110
	.loh AdrpLdrGotLdr	Lloh105, Lloh106, Lloh107
	.loh AdrpLdrGotLdr	Lloh111, Lloh112, Lloh113
	.loh AdrpLdrGotLdr	Lloh114, Lloh115, Lloh116
	.loh AdrpLdrGotLdr	Lloh117, Lloh118, Lloh119
	.loh AdrpLdrGotLdr	Lloh123, Lloh124, Lloh125
	.loh AdrpLdrGotLdr	Lloh120, Lloh121, Lloh122
	.loh AdrpLdrGotLdr	Lloh126, Lloh127, Lloh128
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_PHYS,4,2                   ; @MAX_PHYS
	.comm	_INT_PHY,8,3                    ; @INT_PHY
	.comm	_PHY_HALF_OPEN_CONN_FLAG,8,3    ; @PHY_HALF_OPEN_CONN_FLAG
	.comm	_LINK_UPDATE_MASK,8,3           ; @LINK_UPDATE_MASK
	.comm	_DUPLEX_FULL,4,2                ; @DUPLEX_FULL
	.comm	_NETIF_MSG_LINK,4,2             ; @NETIF_MSG_LINK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"port %x, XGXS?%x, int_status 0x%x\n"

	.comm	_PHY_XGXS_FLAG,8,3              ; @PHY_XGXS_FLAG
	.comm	_NIG_REG_STATUS_INTERRUPT_PORT0,8,3 ; @NIG_REG_STATUS_INTERRUPT_PORT0
	.comm	_NIG_REG_EMAC0_STATUS_MISC_MI_INT,8,3 ; @NIG_REG_EMAC0_STATUS_MISC_MI_INT
l_.str.1:                               ; @.str.1
	.asciz	"int_mask 0x%x MI_INT %x, SERDES_LINK %x\n"

	.comm	_NIG_REG_MASK_INTERRUPT_PORT0,8,3 ; @NIG_REG_MASK_INTERRUPT_PORT0
	.comm	_NIG_REG_SERDES0_STATUS_LINK_STATUS,8,3 ; @NIG_REG_SERDES0_STATUS_LINK_STATUS
l_.str.2:                               ; @.str.2
	.asciz	" 10G %x, XGXS_LINK %x\n"

	.comm	_NIG_REG_XGXS0_STATUS_LINK10G,8,3 ; @NIG_REG_XGXS0_STATUS_LINK10G
	.comm	_NIG_REG_XGXS0_STATUS_LINK_STATUS,8,3 ; @NIG_REG_XGXS0_STATUS_LINK_STATUS
	.comm	_NIG_REG_NIG_EMAC0_EN,8,3       ; @NIG_REG_NIG_EMAC0_EN
	.comm	_EXT_PHY1,8,3                   ; @EXT_PHY1
l_.str.3:                               ; @.str.3
	.asciz	"phy in index %d link is up\n"

l_.str.4:                               ; @.str.4
	.asciz	"phy in index %d link is down\n"

	.comm	_EXT_PHY2,8,3                   ; @EXT_PHY2
l_.str.5:                               ; @.str.5
	.asciz	"Invalid link indicationmpc=0x%x. DISABLING LINK !!!\n"

l_.str.6:                               ; @.str.6
	.asciz	"Disabling TX on EXT_PHY2\n"

	.comm	_DISABLE_TX,4,2                 ; @DISABLE_TX
	.comm	_SUPPORTED_FIBRE,4,2            ; @SUPPORTED_FIBRE
	.comm	_LINK_STATUS_SERDES_LINK,8,3    ; @LINK_STATUS_SERDES_LINK
l_.str.7:                               ; @.str.7
	.asciz	"Active external phy selected: %x\n"

	.comm	_FLAGS_REARM_LATCH_SIGNAL,4,2   ; @FLAGS_REARM_LATCH_SIGNAL
l_.str.8:                               ; @.str.8
	.asciz	"vars->flow_ctrl = 0x%x, vars->link_status = 0x%x, ext_phy_line_speed = %d\n"

l_.str.9:                               ; @.str.9
	.asciz	"Internal link speed %d is different than the external link speed %d\n"

	.comm	_NIG_REG_EGRESS_DRAIN0_MODE,8,3 ; @NIG_REG_EGRESS_DRAIN0_MODE
	.comm	_SPEED_10000,8,3                ; @SPEED_10000
l_.str.10:                              ; @.str.10
	.asciz	"ext_phy_link_up = %d, int_link_up = %d, init_preceding = %d\n"

	.comm	_FLAGS_INIT_XGXS_FIRST,8,3      ; @FLAGS_INIT_XGXS_FIRST
	.comm	_SPEED_1000,8,3                 ; @SPEED_1000
	.comm	_PHY_SGMII_FLAG,8,3             ; @PHY_SGMII_FLAG
	.comm	_FEATURE_CONFIG_PFC_ENABLED,4,2 ; @FEATURE_CONFIG_PFC_ENABLED
	.comm	_LINK_STATUS_PFC_ENABLED,8,3    ; @LINK_STATUS_PFC_ENABLED
	.comm	_FEATURE_CONFIG_BC_SUPPORTS_AFEX,4,2 ; @FEATURE_CONFIG_BC_SUPPORTS_AFEX
	.comm	_DRV_MSG_CODE_LINK_STATUS_CHANGED,4,2 ; @DRV_MSG_CODE_LINK_STATUS_CHANGED
.subsections_via_symbols
