aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ixgbe/ixgbe_82599.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/ixgbe/ixgbe_82599.c')
-rw-r--r--drivers/net/ixgbe/ixgbe_82599.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/drivers/net/ixgbe/ixgbe_82599.c b/drivers/net/ixgbe/ixgbe_82599.c
index 5ee560855268..61af47e75aa1 100644
--- a/drivers/net/ixgbe/ixgbe_82599.c
+++ b/drivers/net/ixgbe/ixgbe_82599.c
@@ -421,15 +421,6 @@ s32 ixgbe_setup_mac_link_multispeed_fiber(struct ixgbe_hw *hw,
421 hw->mac.ops.get_link_capabilities(hw, &phy_link_speed, &negotiation); 421 hw->mac.ops.get_link_capabilities(hw, &phy_link_speed, &negotiation);
422 speed &= phy_link_speed; 422 speed &= phy_link_speed;
423 423
424 /* Set autoneg_advertised value based on input link speed */
425 hw->phy.autoneg_advertised = 0;
426
427 if (speed & IXGBE_LINK_SPEED_10GB_FULL)
428 hw->phy.autoneg_advertised |= IXGBE_LINK_SPEED_10GB_FULL;
429
430 if (speed & IXGBE_LINK_SPEED_1GB_FULL)
431 hw->phy.autoneg_advertised |= IXGBE_LINK_SPEED_1GB_FULL;
432
433 /* 424 /*
434 * When the driver changes the link speeds that it can support, 425 * When the driver changes the link speeds that it can support,
435 * it sets autotry_restart to true to indicate that we need to 426 * it sets autotry_restart to true to indicate that we need to
@@ -466,7 +457,7 @@ s32 ixgbe_setup_mac_link_multispeed_fiber(struct ixgbe_hw *hw,
466 autoneg, 457 autoneg,
467 autoneg_wait_to_complete); 458 autoneg_wait_to_complete);
468 if (status != 0) 459 if (status != 0)
469 goto out; 460 return status;
470 461
471 /* Flap the tx laser if it has not already been done */ 462 /* Flap the tx laser if it has not already been done */
472 if (hw->mac.autotry_restart) { 463 if (hw->mac.autotry_restart) {
@@ -520,7 +511,7 @@ s32 ixgbe_setup_mac_link_multispeed_fiber(struct ixgbe_hw *hw,
520 autoneg, 511 autoneg,
521 autoneg_wait_to_complete); 512 autoneg_wait_to_complete);
522 if (status != 0) 513 if (status != 0)
523 goto out; 514 return status;
524 515
525 /* Flap the tx laser if it has not already been done */ 516 /* Flap the tx laser if it has not already been done */
526 if (hw->mac.autotry_restart) { 517 if (hw->mac.autotry_restart) {
@@ -558,6 +549,15 @@ s32 ixgbe_setup_mac_link_multispeed_fiber(struct ixgbe_hw *hw,
558 autoneg_wait_to_complete); 549 autoneg_wait_to_complete);
559 550
560out: 551out:
552 /* Set autoneg_advertised value based on input link speed */
553 hw->phy.autoneg_advertised = 0;
554
555 if (speed & IXGBE_LINK_SPEED_10GB_FULL)
556 hw->phy.autoneg_advertised |= IXGBE_LINK_SPEED_10GB_FULL;
557
558 if (speed & IXGBE_LINK_SPEED_1GB_FULL)
559 hw->phy.autoneg_advertised |= IXGBE_LINK_SPEED_1GB_FULL;
560
561 return status; 561 return status;
562} 562}
563 563