aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/igb/igb_main.c
diff options
context:
space:
mode:
authorKoki Sanagi <sanagi.koki@jp.fujitsu.com>2013-01-16 11:05:53 +0000
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2013-04-24 20:24:18 -0700
commitc0ba477807191d04f95057a58e08c88ad27b284c (patch)
tree59512d8d66cf402cd4a4ac3e9f18f372ecb53d0e /drivers/net/ethernet/intel/igb/igb_main.c
parentigb: Use pci_vfs_assigned instead of igb_vfs_are_assigned (diff)
downloadlinux-dev-c0ba477807191d04f95057a58e08c88ad27b284c.tar.xz
linux-dev-c0ba477807191d04f95057a58e08c88ad27b284c.zip
igb: display a warning message when SmartSpeed works
Current igb driver doesn't tell nothing when Link Speed is downgraded due to SmartSpeed. As a result, users suspect that there is something wrong with NIC. If the cause of it is SmartSpeed, there is no means to replace NIC. This patch make igb notify users that SmartSpeed worked. Signed-off-by: Koki Sanagi <sanagi.koki@jp.fujitsu.com> Tested-by: Aaron Brown <aaron.f.brown@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to '')
-rw-r--r--drivers/net/ethernet/intel/igb/igb_main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c
index b94a3c551d31..93be6eced2e3 100644
--- a/drivers/net/ethernet/intel/igb/igb_main.c
+++ b/drivers/net/ethernet/intel/igb/igb_main.c
@@ -3901,6 +3901,7 @@ static void igb_watchdog_task(struct work_struct *work)
struct igb_adapter,
watchdog_task);
struct e1000_hw *hw = &adapter->hw;
+ struct e1000_phy_info *phy = &hw->phy;
struct net_device *netdev = adapter->netdev;
u32 link;
int i;
@@ -3929,6 +3930,11 @@ static void igb_watchdog_task(struct work_struct *work)
(ctrl & E1000_CTRL_RFCE) ? "RX" :
(ctrl & E1000_CTRL_TFCE) ? "TX" : "None");
+ /* check if SmartSpeed worked */
+ igb_check_downshift(hw);
+ if (phy->speed_downgraded)
+ netdev_warn(netdev, "Link Speed was downgraded by SmartSpeed\n");
+
/* check for thermal sensor event */
if (igb_thermal_sensor_event(hw,
E1000_THSTAT_LINK_THROTTLE)) {