]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commit
mv643xx_eth: fix NAPI 'rotting packet' issue
authorLennert Buytenhek <buytenh@wantstofly.org>
Sun, 24 Aug 2008 00:45:32 +0000 (02:45 +0200)
committerLennert Buytenhek <buytenh@marvell.com>
Sun, 24 Aug 2008 01:32:56 +0000 (03:32 +0200)
commit819ddcafb33136f2ba18018a22edcf857f640528
treee9cffe7c32e761da3a495bd51d1a9d5929a803dc
parent6a55617ed5d1aa62b850de2cf66f5ede2eef4825
mv643xx_eth: fix NAPI 'rotting packet' issue

When a receive interrupt occurs, mv643xx_eth would first process the
receive descriptors and then ACK the receive interrupt, instead of the
other way round.

This would leave a small race window between processing the last
receive descriptor and clearing the receive interrupt status in which
a new packet could come in, which would then 'rot' in the receive
ring until the next receive interrupt would come in.

Fix this by ACKing (clearing) the receive interrupt condition before
processing the receive descriptors.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
drivers/net/mv643xx_eth.c