Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 224518
b: refs/heads/master
c: 20f70dd
h: refs/heads/master
v: v3
  • Loading branch information
Jonas Bonn authored and David S. Miller committed Nov 28, 2010
1 parent 2d239f1 commit 10da88a
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 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: 7438a5455734d109fdf18d97147dc57a6dbe5a44
refs/heads/master: 20f70ddd6558a39a89dba4af675686c5a8dbd7b3
15 changes: 13 additions & 2 deletions trunk/drivers/net/ethoc.c
Original file line number Diff line number Diff line change
Expand Up @@ -414,8 +414,19 @@ static int ethoc_rx(struct net_device *dev, int limit)

entry = priv->num_tx + (priv->cur_rx % priv->num_rx);
ethoc_read_bd(priv, entry, &bd);
if (bd.stat & RX_BD_EMPTY)
break;
if (bd.stat & RX_BD_EMPTY) {
ethoc_ack_irq(priv, INT_MASK_RX);
/* If packet (interrupt) came in between checking
* BD_EMTPY and clearing the interrupt source, then we
* risk missing the packet as the RX interrupt won't
* trigger right away when we reenable it; hence, check
* BD_EMTPY here again to make sure there isn't such a
* packet waiting for us...
*/
ethoc_read_bd(priv, entry, &bd);
if (bd.stat & RX_BD_EMPTY)
break;
}

if (ethoc_update_rx_stats(priv, &bd) == 0) {
int size = bd.stat >> 16;
Expand Down

0 comments on commit 10da88a

Please sign in to comment.