Commit c2d5ab49 authored by Jesse Brandeburg's avatar Jesse Brandeburg Committed by David S. Miller

e1000/e1000e/igb/ixgb: don't txhang after link down

after the recent changes to wired drivers to use only
netif_carrier_off the driver can have outstanding tx work to
complete that will never complete once link is down.  Since the
intel hardware will hold this tx work forever, the driver
notices a tx timeout condition internally and might try
to instigate printk and reset of the part with a
netif_stop_queue, which doesn't work because link is down.

Don't bother arming to tx hang detection when link is down.
Signed-off-by: default avatarJesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c9c7d2e5
...@@ -2646,6 +2646,8 @@ static void e1000_watchdog(unsigned long data) ...@@ -2646,6 +2646,8 @@ static void e1000_watchdog(unsigned long data)
* (Do the reset outside of interrupt context). */ * (Do the reset outside of interrupt context). */
adapter->tx_timeout_count++; adapter->tx_timeout_count++;
schedule_work(&adapter->reset_task); schedule_work(&adapter->reset_task);
/* return immediately since reset is imminent */
return;
} }
} }
......
...@@ -3651,6 +3651,8 @@ link_up: ...@@ -3651,6 +3651,8 @@ link_up:
*/ */
adapter->tx_timeout_count++; adapter->tx_timeout_count++;
schedule_work(&adapter->reset_task); schedule_work(&adapter->reset_task);
/* return immediately since reset is imminent */
return;
} }
} }
......
...@@ -2711,6 +2711,8 @@ link_up: ...@@ -2711,6 +2711,8 @@ link_up:
* (Do the reset outside of interrupt context). */ * (Do the reset outside of interrupt context). */
adapter->tx_timeout_count++; adapter->tx_timeout_count++;
schedule_work(&adapter->reset_task); schedule_work(&adapter->reset_task);
/* return immediately since reset is imminent */
return;
} }
} }
......
...@@ -1140,6 +1140,8 @@ ixgb_watchdog(unsigned long data) ...@@ -1140,6 +1140,8 @@ ixgb_watchdog(unsigned long data)
* to get done, so reset controller to flush Tx. * to get done, so reset controller to flush Tx.
* (Do the reset outside of interrupt context). */ * (Do the reset outside of interrupt context). */
schedule_work(&adapter->tx_timeout_task); schedule_work(&adapter->tx_timeout_task);
/* return immediately since reset is imminent */
return;
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment