]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
cxgb - fix NAPI
authorDivy Le Ray <divy@chelsio.com>
Tue, 27 Nov 2007 21:30:15 +0000 (13:30 -0800)
committerJeff Garzik <jeff@garzik.org>
Sat, 1 Dec 2007 21:32:31 +0000 (16:32 -0500)
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>
drivers/net/chelsio/sge.c [changed mode: 0755->0644]

old mode 100755 (executable)
new mode 100644 (file)
index e8b1036..4b6258f
@@ -1625,11 +1625,9 @@ int t1_poll(struct napi_struct *napi, int budget)
 {
        struct adapter *adapter = container_of(napi, struct adapter, napi);
        struct net_device *dev = adapter->port[0].dev;
-       int work_done;
-
-       work_done = process_responses(adapter, budget);
+       int work_done = process_responses(adapter, budget);
 
-       if (likely(!responses_pending(adapter))) {
+       if (likely(work_done < budget)) {
                netif_rx_complete(dev, napi);
                writel(adapter->sge->respQ.cidx,
                       adapter->regs + A_SG_SLEEPING);