From: Alexander Duyck Date: Tue, 7 Feb 2012 02:29:01 +0000 (+0000) Subject: net: Fix issue with netdev_tx_reset_queue not resetting queue from XOFF state X-Git-Tag: v3.3.6~22 X-Git-Url: https://git.fsl.cs.sunysb.edu/?a=commitdiff_plain;h=3b50cf3c908f2d025617f3e593c132fdfbc0eb4b;p=unionfs-2.6.39.y.git net: Fix issue with netdev_tx_reset_queue not resetting queue from XOFF state [ Upstream commit 5c4903549c05bbb373479e0ce2992573c120654a ] We are seeing dev_watchdog hangs on several drivers. I suspect this is due to the __QUEUE_STATE_STACK_XOFF bit being set prior to a reset for link change, and then not being cleared by netdev_tx_reset_queue. This change corrects that. In addition we were seeing dev_watchdog hangs on igb after running the ethtool tests. We found this to be due to the fact that the ethtool test runs the same logic as ndo_start_xmit, but we were never clearing the XOFF flag since the loopback test in ethtool does not do byte queue accounting. Signed-off-by: Alexander Duyck Tested-by: Stephen Ko Signed-off-by: Jeff Kirsher Signed-off-by: Greg Kroah-Hartman --- diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index ebf59809789..7e472b737d7 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h @@ -1955,6 +1955,7 @@ static inline void netdev_completed_queue(struct net_device *dev, static inline void netdev_tx_reset_queue(struct netdev_queue *q) { #ifdef CONFIG_BQL + clear_bit(__QUEUE_STATE_STACK_XOFF, &q->state); dql_reset(&q->dql); #endif }