Commit 39c68b3f authored by Chuhong Yuan's avatar Chuhong Yuan Committed by David S. Miller

phy: mdio-sun4i: add missed regulator_disable in remove

The driver forgets to disable the regulator in remove like what is done
in probe failure.
Add the missed call to fix it.
Signed-off-by: default avatarChuhong Yuan <hslester96@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 2744bf42
......@@ -145,8 +145,11 @@ static int sun4i_mdio_probe(struct platform_device *pdev)
static int sun4i_mdio_remove(struct platform_device *pdev)
{
struct mii_bus *bus = platform_get_drvdata(pdev);
struct sun4i_mdio_data *data = bus->priv;
mdiobus_unregister(bus);
if (data->regulator)
regulator_disable(data->regulator);
mdiobus_free(bus);
return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment