aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/e1000e/ethtool.c
diff options
context:
space:
mode:
authorBruce Allan <bruce.w.allan@intel.com>2011-01-06 02:02:53 -0500
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2011-01-24 03:13:56 -0500
commit90da06692532541a38f9857972e1fd6b1cdfb45a (patch)
treeb57994ef65c615e0cf34a57f692fed67b95f3dd1 /drivers/net/e1000e/ethtool.c
parent67fd4fcb78a7ced369a6bd8a131ec8c65ebd2bbb (diff)
e1000e: reduce scope of some variables, remove unnecessary ones
Static analysis of the driver code found some variables for which the scope can be reduced, or remove the variable altogether. Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/e1000e/ethtool.c')
-rw-r--r--drivers/net/e1000e/ethtool.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/e1000e/ethtool.c b/drivers/net/e1000e/ethtool.c
index dfa44de9cf0d..323fd12c306b 100644
--- a/drivers/net/e1000e/ethtool.c
+++ b/drivers/net/e1000e/ethtool.c
@@ -1255,7 +1255,6 @@ static int e1000_integrated_phy_loopback(struct e1000_adapter *adapter)
1255{ 1255{
1256 struct e1000_hw *hw = &adapter->hw; 1256 struct e1000_hw *hw = &adapter->hw;
1257 u32 ctrl_reg = 0; 1257 u32 ctrl_reg = 0;
1258 u32 stat_reg = 0;
1259 u16 phy_reg = 0; 1258 u16 phy_reg = 0;
1260 s32 ret_val = 0; 1259 s32 ret_val = 0;
1261 1260
@@ -1363,8 +1362,7 @@ static int e1000_integrated_phy_loopback(struct e1000_adapter *adapter)
1363 * Set the ILOS bit on the fiber Nic if half duplex link is 1362 * Set the ILOS bit on the fiber Nic if half duplex link is
1364 * detected. 1363 * detected.
1365 */ 1364 */
1366 stat_reg = er32(STATUS); 1365 if ((er32(STATUS) & E1000_STATUS_FD) == 0)
1367 if ((stat_reg & E1000_STATUS_FD) == 0)
1368 ctrl_reg |= (E1000_CTRL_ILOS | E1000_CTRL_SLU); 1366 ctrl_reg |= (E1000_CTRL_ILOS | E1000_CTRL_SLU);
1369 } 1367 }
1370 1368