net: phy: ti: take into account all possible interrupt sources
authorIoana Ciornei <ioana.ciornei@nxp.com>
Fri, 26 Feb 2021 15:30:20 +0000 (17:30 +0200)
committerJakub Kicinski <kuba@kernel.org>
Mon, 1 Mar 2021 19:46:55 +0000 (11:46 -0800)
commit73f476aa1975bae6a792b340f5b26ffcfba869a6
tree32a9a807fe43d1c883d92b7e678f737103e9d2a8
parent447621e373bd1b22300445639b43c39f399e4c73
net: phy: ti: take into account all possible interrupt sources

The previous implementation of .handle_interrupt() did not take into
account the fact that all the interrupt status registers should be
acknowledged since multiple interrupt sources could be asserted.

Fix this by reading all the status registers before exiting with
IRQ_NONE or triggering the PHY state machine.

Fixes: 1d1ae3c6ca3f ("net: phy: ti: implement generic .handle_interrupt() callback")
Reported-by: Sven Schuchmann <schuchmann@schleissheimer.de>
Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Link: https://lore.kernel.org/r/20210226153020.867852-1-ciorneiioana@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/phy/dp83822.c
drivers/net/phy/dp83tc811.c