Commit 99728347 authored by Fugang Duan's avatar Fugang Duan Committed by Greg Kroah-Hartman

net: fec: correct the error path for regulator disable in probe

[ Upstream commit c6165cf0 ]

Correct the error path for regulator disable.

Fixes: 9269e556 ("net: fec: add phy-reset-gpios PROBE_DEFER check")
Signed-off-by: default avatarFugang Duan <fugang.duan@nxp.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 46858b2f
...@@ -3659,11 +3659,11 @@ fec_probe(struct platform_device *pdev) ...@@ -3659,11 +3659,11 @@ fec_probe(struct platform_device *pdev)
failed_irq: failed_irq:
failed_init: failed_init:
fec_ptp_stop(pdev); fec_ptp_stop(pdev);
if (fep->reg_phy)
regulator_disable(fep->reg_phy);
failed_reset: failed_reset:
pm_runtime_put_noidle(&pdev->dev); pm_runtime_put_noidle(&pdev->dev);
pm_runtime_disable(&pdev->dev); pm_runtime_disable(&pdev->dev);
if (fep->reg_phy)
regulator_disable(fep->reg_phy);
failed_regulator: failed_regulator:
clk_disable_unprepare(fep->clk_ahb); clk_disable_unprepare(fep->clk_ahb);
failed_clk_ahb: failed_clk_ahb:
......
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