]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: phy: call phy_disable_interrupts() in phy_attach_direct() instead
authorYoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Wed, 9 Sep 2020 05:43:14 +0000 (14:43 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 26 Sep 2020 16:05:23 +0000 (18:05 +0200)
commit9286233285ba5dd927333f83d8654fb967dfef74
treea658fe0f7c6933af87a2812c1b1c135f8c7f93df
parente9fd16fc0c7ddcdd66025e614c4120a6b97a5721
net: phy: call phy_disable_interrupts() in phy_attach_direct() instead

[ Upstream commit 7d3ba9360c6dac7c077fbd6631e08f32ea2bcd53 ]

Since the micrel phy driver calls phy_init_hw() as a workaround,
the commit 9886a4dbd2aa ("net: phy: call phy_disable_interrupts()
in phy_init_hw()") disables the interrupt unexpectedly. So,
call phy_disable_interrupts() in phy_attach_direct() instead.
Otherwise, the phy cannot link up after the ethernet cable was
disconnected.

Note that other drivers (like at803x.c) also calls phy_init_hw().
So, perhaps, the driver caused a similar issue too.

Fixes: 9886a4dbd2aa ("net: phy: call phy_disable_interrupts() in phy_init_hw()")
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/phy/phy_device.c