]> err.no Git - linux-2.6/commit
[BNX2]: Refine napi poll loop.
authorMichael Chan <mchan@broadcom.com>
Fri, 12 Oct 2007 08:40:38 +0000 (01:40 -0700)
committerDavid S. Miller <davem@sunset.davemloft.net>
Fri, 12 Oct 2007 09:01:21 +0000 (02:01 -0700)
commit6dee6421581d3484e9a01d403dbf158161942db6
tree57a9ba4782217e9c962230e9566ac32c06cb1fb4
parent4fd7ab5949edfdf99be0ceef206c9d0b7f186318
[BNX2]: Refine napi poll loop.

Need to read and store sblk->status_idx before checking for more work.
The status idx is later written back to the hardware when enabling
interrupts to acknowledge how much work has been processed.  If the
order is reversed, we can end up acknowledging work we haven't
processed.

When completing bnx2_poll(), we should always break out of the while
loop and return work_done instead of returning 0.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/bnx2.c