The check was missing on PCIe resume. Signed-off-by: Jim Quinlan <jim2101024@xxxxxxxxx> Acked-by: Florian Fainelli <f.fainelli@xxxxxxxxx> Fixes: 8195b7417018 ("PCI: brcmstb: Add suspend and resume pm_ops") --- drivers/pci/controller/pcie-brcmstb.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/pci/controller/pcie-brcmstb.c b/drivers/pci/controller/pcie-brcmstb.c index 2d9288399014..f6d9d785b301 100644 --- a/drivers/pci/controller/pcie-brcmstb.c +++ b/drivers/pci/controller/pcie-brcmstb.c @@ -1396,7 +1396,9 @@ static int brcm_pcie_resume(struct device *dev) int ret; base = pcie->base; - clk_prepare_enable(pcie->clk); + ret = clk_prepare_enable(pcie->clk); + if (ret) + return ret; ret = brcm_set_regulators(pcie, TURN_ON); if (ret) @@ -1535,7 +1537,9 @@ static int brcm_pcie_probe(struct platform_device *pdev) ret = brcm_pcie_get_regulators(pcie); if (ret) { - dev_err(pcie->dev, "failed to get regulators (err=%d)\n", ret); + pcie->num_supplies = 0; + if (ret != -EPROBE_DEFER) + dev_err(pcie->dev, "failed to get regulators (err=%d)\n", ret); goto fail; } -- 2.17.1