Message ID | 1260965365-14255-2-git-send-email-leitao@linux.vnet.ibm.com |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
On Wed, 2009-12-16 at 04:09 -0800, leitao@linux.vnet.ibm.com wrote: > When running the following script on an active bnx2 interface: > > while(true); do ifconfig ethX mtu 9000; ifconfig ethX mtu 1500; done > > A timeout error appears and dumps the following stack: > > NETDEV WATCHDOG: eth4 (bnx2): transmit queue 0 timed out > ------------[ cut here ]------------ > Badness at net/sched/sch_generic.c:261 > <snip> > > This patch just fixes the way that ->trans_start is refreshed. > > Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com> Thanks. Acked-by: Michael Chan <mchan@broadcom.com> > --- > drivers/net/bnx2.c | 10 +++++++++- > 1 files changed, 9 insertions(+), 1 deletions(-) > > diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c > index 4bfc808..f81f082 100644 > --- a/drivers/net/bnx2.c > +++ b/drivers/net/bnx2.c > @@ -655,9 +655,17 @@ bnx2_netif_stop(struct bnx2 *bp) > bnx2_cnic_stop(bp); > bnx2_disable_int_sync(bp); > if (netif_running(bp->dev)) { > + int i; > + > bnx2_napi_disable(bp); > netif_tx_disable(bp->dev); > - bp->dev->trans_start = jiffies; /* prevent tx timeout */ > + /* prevent tx timeout */ > + for (i = 0; i < bp->dev->num_tx_queues; i++) { > + struct netdev_queue *txq; > + > + txq = netdev_get_tx_queue(bp->dev, i); > + txq->trans_start = jiffies; > + } > } > } > -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: "Michael Chan" <mchan@broadcom.com> Date: Wed, 16 Dec 2009 10:33:30 -0800 > > On Wed, 2009-12-16 at 04:09 -0800, leitao@linux.vnet.ibm.com wrote: >> When running the following script on an active bnx2 interface: >> >> while(true); do ifconfig ethX mtu 9000; ifconfig ethX mtu 1500; done >> >> A timeout error appears and dumps the following stack: >> >> NETDEV WATCHDOG: eth4 (bnx2): transmit queue 0 timed out >> ------------[ cut here ]------------ >> Badness at net/sched/sch_generic.c:261 >> <snip> >> >> This patch just fixes the way that ->trans_start is refreshed. >> >> Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com> > > Thanks. Acked-by: Michael Chan <mchan@broadcom.com> Applied, thanks everyone. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c index 4bfc808..f81f082 100644 --- a/drivers/net/bnx2.c +++ b/drivers/net/bnx2.c @@ -655,9 +655,17 @@ bnx2_netif_stop(struct bnx2 *bp) bnx2_cnic_stop(bp); bnx2_disable_int_sync(bp); if (netif_running(bp->dev)) { + int i; + bnx2_napi_disable(bp); netif_tx_disable(bp->dev); - bp->dev->trans_start = jiffies; /* prevent tx timeout */ + /* prevent tx timeout */ + for (i = 0; i < bp->dev->num_tx_queues; i++) { + struct netdev_queue *txq; + + txq = netdev_get_tx_queue(bp->dev, i); + txq->trans_start = jiffies; + } } }
When running the following script on an active bnx2 interface: while(true); do ifconfig ethX mtu 9000; ifconfig ethX mtu 1500; done A timeout error appears and dumps the following stack: NETDEV WATCHDOG: eth4 (bnx2): transmit queue 0 timed out ------------[ cut here ]------------ Badness at net/sched/sch_generic.c:261 <snip> This patch just fixes the way that ->trans_start is refreshed. Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com> --- drivers/net/bnx2.c | 10 +++++++++- 1 files changed, 9 insertions(+), 1 deletions(-)