mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-19 13:41:31 +00:00
net: phy: delay only if reset handler is registered
With commit e3a77218a2
the MII bus is only
reset if a reset handler is registered. If there is no reset handler there
is no need to wait for a device to come out of the reset.
Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
This commit is contained in:
parent
2c171a2a5f
commit
59370f3fcd
1 changed files with 5 additions and 3 deletions
|
@ -763,11 +763,13 @@ struct phy_device *phy_find_by_mask(struct mii_dev *bus, unsigned phy_mask,
|
||||||
phy_interface_t interface)
|
phy_interface_t interface)
|
||||||
{
|
{
|
||||||
/* Reset the bus */
|
/* Reset the bus */
|
||||||
if (bus->reset)
|
if (bus->reset) {
|
||||||
bus->reset(bus);
|
bus->reset(bus);
|
||||||
|
|
||||||
/* Wait 15ms to make sure the PHY has come out of hard reset */
|
/* Wait 15ms to make sure the PHY has come out of hard reset */
|
||||||
udelay(15000);
|
udelay(15000);
|
||||||
|
}
|
||||||
|
|
||||||
return get_phy_device_by_mask(bus, phy_mask, interface);
|
return get_phy_device_by_mask(bus, phy_mask, interface);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue