]> git.baikalelectronics.ru Git - kernel.git/commit
net: usb: lan78xx: Fix suspend/resume PHY register access error
authorCristian Birsan <cristian.birsan@microchip.com>
Thu, 12 Dec 2019 11:52:47 +0000 (13:52 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 12 Dec 2019 18:57:12 +0000 (10:57 -0800)
commitce3f86ead2cca5986e51b71ed118a53afe44b3f1
treee29cf37e5e70cf66a099251b53324f39823512e6
parent993dbfdc3e50ecfe8c326a298232a68b546b0ad0
net: usb: lan78xx: Fix suspend/resume PHY register access error

Lan78xx driver accesses the PHY registers through MDIO bus over USB
connection. When performing a suspend/resume, the PHY registers can be
accessed before the USB connection is resumed. This will generate an
error and will prevent the device to resume correctly.
This patch adds the dependency between the MDIO bus and USB device to
allow correct handling of suspend/resume.

Fixes: 463189e2dcf4 ("lan78xx: Update to use phylib instead of mii_if_info.")
Signed-off-by: Cristian Birsan <cristian.birsan@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/lan78xx.c