浏览代码

bnx2x: fix napi poll return value for repoll

With the commit d75b1ade567ffab ("net: less interrupt masking in NAPI") napi
repoll is done only when work_done == budget. When in busy_poll is we return 0
in napi_poll. We should return budget.

Signed-off-by: Govindarajulu Varadarajan <_govind@gmx.com>
Acked-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Govindarajulu Varadarajan 10 年之前
父节点
当前提交
24e579c889
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c

+ 1 - 1
drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c

@@ -3175,7 +3175,7 @@ static int bnx2x_poll(struct napi_struct *napi, int budget)
 		}
 		}
 #endif
 #endif
 		if (!bnx2x_fp_lock_napi(fp))
 		if (!bnx2x_fp_lock_napi(fp))
-			return work_done;
+			return budget;
 
 
 		for_each_cos_in_tx_queue(fp, cos)
 		for_each_cos_in_tx_queue(fp, cos)
 			if (bnx2x_tx_queue_has_work(fp->txdata_ptr[cos]))
 			if (bnx2x_tx_queue_has_work(fp->txdata_ptr[cos]))