aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c
diff options
context:
space:
mode:
authorJosh Hay <joshua.a.hay@intel.com>2012-12-14 22:28:30 -0500
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2013-02-01 00:57:19 -0500
commitfd0326f2cf9e5d1d3dbcf4ea0da9accc762c4e52 (patch)
tree3c6a942b800077123180dd3f764d1041d0648b44 /drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c
parent99b76642ca28841fe71c870a3bfbcb164fe04388 (diff)
ixgbe: autoneg variable refactoring
Removes the autoneg parameter from the setup_link functions. Adds local variable autoneg to setup_link functions to be passed to get_link_capabilities functions if needed. Signed-off-by: Josh Hay <joshua.a.hay@intel.com> Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c')
-rw-r--r--drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c
index 1513b1052ee2..216203ece6ed 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c
@@ -156,7 +156,7 @@ static int ixgbe_get_settings(struct net_device *netdev,
156 struct ixgbe_hw *hw = &adapter->hw; 156 struct ixgbe_hw *hw = &adapter->hw;
157 ixgbe_link_speed supported_link; 157 ixgbe_link_speed supported_link;
158 u32 link_speed = 0; 158 u32 link_speed = 0;
159 bool autoneg; 159 bool autoneg = false;
160 bool link_up; 160 bool link_up;
161 161
162 hw->mac.ops.get_link_capabilities(hw, &supported_link, &autoneg); 162 hw->mac.ops.get_link_capabilities(hw, &supported_link, &autoneg);
@@ -333,10 +333,10 @@ static int ixgbe_set_settings(struct net_device *netdev,
333 return err; 333 return err;
334 /* this sets the link speed and restarts auto-neg */ 334 /* this sets the link speed and restarts auto-neg */
335 hw->mac.autotry_restart = true; 335 hw->mac.autotry_restart = true;
336 err = hw->mac.ops.setup_link(hw, advertised, true, true); 336 err = hw->mac.ops.setup_link(hw, advertised, true);
337 if (err) { 337 if (err) {
338 e_info(probe, "setup link failed with code %d\n", err); 338 e_info(probe, "setup link failed with code %d\n", err);
339 hw->mac.ops.setup_link(hw, old, true, true); 339 hw->mac.ops.setup_link(hw, old, true);
340 } 340 }
341 } else { 341 } else {
342 /* in this case we currently only support 10Gb/FULL */ 342 /* in this case we currently only support 10Gb/FULL */