Skip to content
Snippets Groups Projects
Commit 59370f3f authored by Jörg Krause's avatar Jörg Krause Committed by Joe Hershberger
Browse files

net: phy: delay only if reset handler is registered


With commit e3a77218 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: default avatarJörg Krause <joerg.krause@embedded.rocks>
parent 2c171a2a
No related branches found
No related tags found
No related merge requests found
......@@ -763,11 +763,13 @@ struct phy_device *phy_find_by_mask(struct mii_dev *bus, unsigned phy_mask,
phy_interface_t interface)
{
/* Reset the bus */
if (bus->reset)
if (bus->reset) {
bus->reset(bus);
/* Wait 15ms to make sure the PHY has come out of hard reset */
udelay(15000);
/* Wait 15ms to make sure the PHY has come out of hard reset */
udelay(15000);
}
return get_phy_device_by_mask(bus, phy_mask, interface);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment