diff options
author | Divy Le Ray <divy@chelsio.com> | 2007-11-27 16:30:15 -0500 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2007-12-01 16:32:31 -0500 |
commit | 445cf803ca757a5c43f4e11fdfba70355d510841 (patch) | |
tree | a818c54ffbc86ebcaed523d84d7d99d2b5c98662 /drivers/net/chelsio | |
parent | 7832ee034b6ef78aab020c9ec1348544cd65ccbd (diff) |
cxgb - fix NAPI
netif_rx_complete() should be called only
when work_done < budget.
Signed-off-by: Divy Le ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/chelsio')
-rw-r--r--[-rwxr-xr-x] | drivers/net/chelsio/sge.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/chelsio/sge.c b/drivers/net/chelsio/sge.c index e8b1036672ae..4b6258fc726f 100755..100644 --- a/drivers/net/chelsio/sge.c +++ b/drivers/net/chelsio/sge.c | |||
@@ -1625,11 +1625,9 @@ int t1_poll(struct napi_struct *napi, int budget) | |||
1625 | { | 1625 | { |
1626 | struct adapter *adapter = container_of(napi, struct adapter, napi); | 1626 | struct adapter *adapter = container_of(napi, struct adapter, napi); |
1627 | struct net_device *dev = adapter->port[0].dev; | 1627 | struct net_device *dev = adapter->port[0].dev; |
1628 | int work_done; | 1628 | int work_done = process_responses(adapter, budget); |
1629 | |||
1630 | work_done = process_responses(adapter, budget); | ||
1631 | 1629 | ||
1632 | if (likely(!responses_pending(adapter))) { | 1630 | if (likely(work_done < budget)) { |
1633 | netif_rx_complete(dev, napi); | 1631 | netif_rx_complete(dev, napi); |
1634 | writel(adapter->sge->respQ.cidx, | 1632 | writel(adapter->sge->respQ.cidx, |
1635 | adapter->regs + A_SG_SLEEPING); | 1633 | adapter->regs + A_SG_SLEEPING); |