Disable vpcie0v9 regulator if resume_noirq fails.
Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
err = rockchip_pcie_enable_clocks(rockchip);
if (err)
- return err;
+ goto err_disable_0v9;
err = rockchip_pcie_init_port(rockchip);
if (err)
rockchip_pcie_deinit_phys(rockchip);
err_pcie_resume:
rockchip_pcie_disable_clocks(rockchip);
+err_disable_0v9:
+ if (!IS_ERR(rockchip->vpcie0v9))
+ regulator_disable(rockchip->vpcie0v9);
return err;
}