]> git.itanic.dy.fi Git - linux-stable/commit
net: ethernet: ti: cpsw: fix extra rx interrupt
authorGrygorii Strashko <grygorii.strashko@ti.com>
Fri, 6 Dec 2019 12:28:20 +0000 (14:28 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 21 Dec 2019 09:57:11 +0000 (10:57 +0100)
commit64334e4f982585c1eb53d3cc067c5641aac0122b
treef1c7f3b8ea076ad81ec2f1468bd85ba74797362e
parenta7d80e75596bf0f115e857ca4243d01dc18bdf5d
net: ethernet: ti: cpsw: fix extra rx interrupt

[ Upstream commit 51302f77bedab8768b761ed1899c08f89af9e4e2 ]

Now RX interrupt is triggered twice every time, because in
cpsw_rx_interrupt() it is asked first and then disabled. So there will be
pending interrupt always, when RX interrupt is enabled again in NAPI
handler.

Fix it by first disabling IRQ and then do ask.

Fixes: 870915feabdc ("drivers: net: cpsw: remove disable_irq/enable_irq as irq can be masked from cpsw itself")
Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/ti/cpsw.c