igb: Reset the link when EEE setting changed
authorAkeem G Abodunrin <akeem.g.abodunrin@intel.com>
Fri, 24 May 2013 07:20:57 +0000 (07:20 +0000)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Thu, 22 Aug 2013 09:25:17 +0000 (02:25 -0700)
This patch resets the link, if link is up - whenever users enable or disable EEE

Signed-off-by: Akeem G Abodunrin <akeem.g.abodunrin@intel.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/igb/igb_ethtool.c

index 85fe7b52f435cf9444cab5d1c466e9e604e3f40b..6d861a5c729a984f684f93c6bb3ad6b4995b5964 100644 (file)
@@ -2672,7 +2672,9 @@ static int igb_set_eee(struct net_device *netdev,
                igb_set_eee_i350(hw);
 
                /* reset link */
-               if (!netif_running(netdev))
+               if (netif_running(netdev))
+                       igb_reinit_locked(adapter);
+               else
                        igb_reset(adapter);
        }