net: fec: clear receive interrupts before processing a packet
authorRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 8 Jul 2014 12:01:49 +0000 (13:01 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 9 Jul 2014 03:57:46 +0000 (20:57 -0700)
commitdb3421c114cfa6326861bc95e604785f4c64293b
tree059c5386f020cef7b71890b9b7d96000c4cd6e1f
parent36cdc743a320e78a5d12ca9765ec0f7d9f07b1f5
net: fec: clear receive interrupts before processing a packet

Clear any pending receive interrupt before we process a pending packet.
This helps to avoid any spurious interrupts being raised after we have
fully cleaned the receive ring, while still allowing an interrupt to be
raised if we receive another packet.

The position of this is critical: we must do this prior to reading the
next packet status to avoid potentially dropping an interrupt when a
packet is still pending.

Acked-by: Fugang Duan <B38611@freescale.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/freescale/fec_main.c