diff options
author | Fugang Duan <fugang.duan@nxp.com> | 2020-08-13 10:13:14 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-08-15 02:48:29 +0300 |
commit | c6165cf0dbb82ded90163dce3ac183fc7a913dc4 (patch) | |
tree | ac5d6d45b7a98bdf3e96b9bc069aa24c3b7c31cb | |
parent | b07e2a86133989cbcb17a9a9a86788f5ec34d846 (diff) | |
download | linux-c6165cf0dbb82ded90163dce3ac183fc7a913dc4.tar.xz |
net: fec: correct the error path for regulator disable in probe
Correct the error path for regulator disable.
Fixes: 9269e5560b26 ("net: fec: add phy-reset-gpios PROBE_DEFER check")
Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/ethernet/freescale/fec_main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/freescale/fec_main.c b/drivers/net/ethernet/freescale/fec_main.c index 9934421814b4..fb37816a74db 100644 --- a/drivers/net/ethernet/freescale/fec_main.c +++ b/drivers/net/ethernet/freescale/fec_main.c @@ -3715,11 +3715,11 @@ failed_mii_init: failed_irq: failed_init: fec_ptp_stop(pdev); - if (fep->reg_phy) - regulator_disable(fep->reg_phy); failed_reset: pm_runtime_put_noidle(&pdev->dev); pm_runtime_disable(&pdev->dev); + if (fep->reg_phy) + regulator_disable(fep->reg_phy); failed_regulator: clk_disable_unprepare(fep->clk_ahb); failed_clk_ahb: |