Commit 61660dbf authored by Anson Huang's avatar Anson Huang Committed by Lorenzo Pieralisi

PCI: imx6: Do not output error message when devm_clk_get() failed with -EPROBE_DEFER

When devm_clk_get() returns -EPROBE_DEFER, i.MX6 PCI driver should
NOT print error message, use dev_err_probe() to handle it.

Link: https://lore.kernel.org/r/1597109364-4739-1-git-send-email-Anson.Huang@nxp.comSigned-off-by: default avatarAnson Huang <Anson.Huang@nxp.com>
Signed-off-by: default avatarLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Reviewed-by: default avatarLucas Stach <l.stach@pengutronix.de>
parent 73abd0bf
...@@ -1073,38 +1073,33 @@ static int imx6_pcie_probe(struct platform_device *pdev) ...@@ -1073,38 +1073,33 @@ static int imx6_pcie_probe(struct platform_device *pdev)
/* Fetch clocks */ /* Fetch clocks */
imx6_pcie->pcie_phy = devm_clk_get(dev, "pcie_phy"); imx6_pcie->pcie_phy = devm_clk_get(dev, "pcie_phy");
if (IS_ERR(imx6_pcie->pcie_phy)) { if (IS_ERR(imx6_pcie->pcie_phy))
dev_err(dev, "pcie_phy clock source missing or invalid\n"); return dev_err_probe(dev, PTR_ERR(imx6_pcie->pcie_phy),
return PTR_ERR(imx6_pcie->pcie_phy); "pcie_phy clock source missing or invalid\n");
}
imx6_pcie->pcie_bus = devm_clk_get(dev, "pcie_bus"); imx6_pcie->pcie_bus = devm_clk_get(dev, "pcie_bus");
if (IS_ERR(imx6_pcie->pcie_bus)) { if (IS_ERR(imx6_pcie->pcie_bus))
dev_err(dev, "pcie_bus clock source missing or invalid\n"); return dev_err_probe(dev, PTR_ERR(imx6_pcie->pcie_bus),
return PTR_ERR(imx6_pcie->pcie_bus); "pcie_bus clock source missing or invalid\n");
}
imx6_pcie->pcie = devm_clk_get(dev, "pcie"); imx6_pcie->pcie = devm_clk_get(dev, "pcie");
if (IS_ERR(imx6_pcie->pcie)) { if (IS_ERR(imx6_pcie->pcie))
dev_err(dev, "pcie clock source missing or invalid\n"); return dev_err_probe(dev, PTR_ERR(imx6_pcie->pcie),
return PTR_ERR(imx6_pcie->pcie); "pcie clock source missing or invalid\n");
}
switch (imx6_pcie->drvdata->variant) { switch (imx6_pcie->drvdata->variant) {
case IMX6SX: case IMX6SX:
imx6_pcie->pcie_inbound_axi = devm_clk_get(dev, imx6_pcie->pcie_inbound_axi = devm_clk_get(dev,
"pcie_inbound_axi"); "pcie_inbound_axi");
if (IS_ERR(imx6_pcie->pcie_inbound_axi)) { if (IS_ERR(imx6_pcie->pcie_inbound_axi))
dev_err(dev, "pcie_inbound_axi clock missing or invalid\n"); return dev_err_probe(dev, PTR_ERR(imx6_pcie->pcie_inbound_axi),
return PTR_ERR(imx6_pcie->pcie_inbound_axi); "pcie_inbound_axi clock missing or invalid\n");
}
break; break;
case IMX8MQ: case IMX8MQ:
imx6_pcie->pcie_aux = devm_clk_get(dev, "pcie_aux"); imx6_pcie->pcie_aux = devm_clk_get(dev, "pcie_aux");
if (IS_ERR(imx6_pcie->pcie_aux)) { if (IS_ERR(imx6_pcie->pcie_aux))
dev_err(dev, "pcie_aux clock source missing or invalid\n"); return dev_err_probe(dev, PTR_ERR(imx6_pcie->pcie_aux),
return PTR_ERR(imx6_pcie->pcie_aux); "pcie_aux clock source missing or invalid\n");
}
fallthrough; fallthrough;
case IMX7D: case IMX7D:
if (dbi_base->start == IMX8MQ_PCIE2_BASE_ADDR) if (dbi_base->start == IMX8MQ_PCIE2_BASE_ADDR)
......
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