mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 19:08:57 +09:00
ethernet: stmmac: Release reset gpio desc for mdio reset
For some PHYs, it is necessary to reset the PHY after waking up from sleep to ensure that it works properly. Change-Id: I629c12096060c8b5ac1a33dfd5a90a85adddec44 Signed-off-by: David Wu <david.wu@rock-chips.com>
This commit is contained in:
@@ -375,6 +375,9 @@ int stmmac_mdio_reset(struct mii_bus *bus)
|
||||
gpiod_set_value_cansleep(reset_gpio, 0);
|
||||
if (delays[2])
|
||||
msleep(DIV_ROUND_UP(delays[2], 1000));
|
||||
|
||||
/* put reset gpio resource for next time */
|
||||
devm_gpiod_put(priv->device, reset_gpio);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user