Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 72989
b: refs/heads/master
c: c956a24
h: refs/heads/master
i:
  72987: a1fd1cc
v: v3
  • Loading branch information
Andrew Gallatin authored and Jeff Garzik committed Nov 1, 2007
1 parent c038a52 commit 4534c18
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 48d58459fe991e48bf7e6638a0ded0f8cbd2fa3b
refs/heads/master: c956a24018819bd903fad0cd275a63c089cdba53
6 changes: 3 additions & 3 deletions trunk/drivers/net/myri10ge/myri10ge.c
Original file line number Diff line number Diff line change
Expand Up @@ -1151,7 +1151,7 @@ static inline int myri10ge_clean_rx_done(struct myri10ge_priv *mgp, int budget)
u16 length;
__wsum checksum;

while (rx_done->entry[idx].length != 0 && work_done++ < budget) {
while (rx_done->entry[idx].length != 0 && work_done < budget) {
length = ntohs(rx_done->entry[idx].length);
rx_done->entry[idx].length = 0;
checksum = csum_unfold(rx_done->entry[idx].checksum);
Expand All @@ -1167,6 +1167,7 @@ static inline int myri10ge_clean_rx_done(struct myri10ge_priv *mgp, int budget)
rx_bytes += rx_ok * (unsigned long)length;
cnt++;
idx = cnt & (myri10ge_max_intr_slots - 1);
work_done++;
}
rx_done->idx = idx;
rx_done->cnt = cnt;
Expand Down Expand Up @@ -1233,13 +1234,12 @@ static int myri10ge_poll(struct napi_struct *napi, int budget)
struct myri10ge_priv *mgp =
container_of(napi, struct myri10ge_priv, napi);
struct net_device *netdev = mgp->dev;
struct myri10ge_rx_done *rx_done = &mgp->rx_done;
int work_done;

/* process as many rx events as NAPI will allow */
work_done = myri10ge_clean_rx_done(mgp, budget);

if (rx_done->entry[rx_done->idx].length == 0 || !netif_running(netdev)) {
if (work_done < budget || !netif_running(netdev)) {
netif_rx_complete(netdev, napi);
put_be32(htonl(3), mgp->irq_claim);
}
Expand Down

0 comments on commit 4534c18

Please sign in to comment.