]> git.baikalelectronics.ru Git - kernel.git/commit
net: usb: smsc95xx: fix external PHY reset
authorAlexandru Tachici <alexandru.tachici@analog.com>
Tue, 15 Nov 2022 11:44:34 +0000 (13:44 +0200)
committerPaolo Abeni <pabeni@redhat.com>
Thu, 17 Nov 2022 09:38:37 +0000 (10:38 +0100)
commitfee3d98801da5610c7440aa8b21db1752a467407
tree66fc351ac1deaa2f7420c23ecf594f2754798faf
parent7ee089581116c504622a217b31d921ca78c958de
net: usb: smsc95xx: fix external PHY reset

An external PHY needs settling time after power up or reset.
In the bind() function an mdio bus is registered. If at this point
the external PHY is still initialising, no valid PHY ID will be
read and on phy_find_first() the bind() function will fail.

If an external PHY is present, wait the maximum time specified
in 802.3 45.2.7.1.1.

Fixes: 2bdbf5a23dc6 ("smsc95xx: add phylib support")
Signed-off-by: Alexandru Tachici <alexandru.tachici@analog.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/20221115114434.9991-2-alexandru.tachici@analog.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/usb/smsc95xx.c