Skip to content

Commit

Permalink
e1000/e1000e/igb/ixgb: don't txhang after link down
Browse files Browse the repository at this point in the history
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: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Jesse Brandeburg authored and David S. Miller committed May 7, 2009
1 parent c9c7d2e commit c2d5ab4
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/e1000/e1000_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2646,6 +2646,8 @@ static void e1000_watchdog(unsigned long data)
* (Do the reset outside of interrupt context). */
adapter->tx_timeout_count++;
schedule_work(&adapter->reset_task);
/* return immediately since reset is imminent */
return;
}
}

Expand Down
2 changes: 2 additions & 0 deletions drivers/net/e1000e/netdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -3651,6 +3651,8 @@ static void e1000_watchdog_task(struct work_struct *work)
*/
adapter->tx_timeout_count++;
schedule_work(&adapter->reset_task);
/* return immediately since reset is imminent */
return;
}
}

Expand Down
2 changes: 2 additions & 0 deletions drivers/net/igb/igb_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2711,6 +2711,8 @@ static void igb_watchdog_task(struct work_struct *work)
* (Do the reset outside of interrupt context). */
adapter->tx_timeout_count++;
schedule_work(&adapter->reset_task);
/* return immediately since reset is imminent */
return;
}
}

Expand Down
2 changes: 2 additions & 0 deletions drivers/net/ixgb/ixgb_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1140,6 +1140,8 @@ ixgb_watchdog(unsigned long data)
* to get done, so reset controller to flush Tx.
* (Do the reset outside of interrupt context). */
schedule_work(&adapter->tx_timeout_task);
/* return immediately since reset is imminent */
return;
}
}

Expand Down

0 comments on commit c2d5ab4

Please sign in to comment.