* [PATCH v2] drm/tegra: hdmi: probe deferral error reporting
@ 2018-08-14 12:53 Marcel Ziswiler
0 siblings, 0 replies; only message in thread
From: Marcel Ziswiler @ 2018-08-14 12:53 UTC (permalink / raw)
To: linux-tegra
Cc: Lucas Stach, Marcel Ziswiler, Thierry Reding, Jonathan Hunter,
linux-kernel, dri-devel, David Airlie
From: Marcel Ziswiler <marcel.ziswiler@toradex.com>
Actually report the error code from devm_regulator_get() unless it
is just a probe deferral.
Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
---
Changes in v2:
- Silence probe deferral as suggested by Lucas.
- Fix line over 80 characters as reported by checkpatch.
drivers/gpu/drm/tegra/hdmi.c | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/tegra/hdmi.c b/drivers/gpu/drm/tegra/hdmi.c
index 0082468f703c..073d54b7225e 100644
--- a/drivers/gpu/drm/tegra/hdmi.c
+++ b/drivers/gpu/drm/tegra/hdmi.c
@@ -1693,14 +1693,22 @@ static int tegra_hdmi_probe(struct platform_device *pdev)
hdmi->hdmi = devm_regulator_get(&pdev->dev, "hdmi");
if (IS_ERR(hdmi->hdmi)) {
- dev_err(&pdev->dev, "failed to get HDMI regulator\n");
- return PTR_ERR(hdmi->hdmi);
+ err = PTR_ERR(hdmi->hdmi);
+ if (err != -EPROBE_DEFER)
+ dev_err(&pdev->dev, "failed to get HDMI regulator: %d\n",
+ err);
+
+ return err;
}
hdmi->pll = devm_regulator_get(&pdev->dev, "pll");
if (IS_ERR(hdmi->pll)) {
- dev_err(&pdev->dev, "failed to get PLL regulator\n");
- return PTR_ERR(hdmi->pll);
+ err = PTR_ERR(hdmi->pll);
+ if (err != -EPROBE_DEFER)
+ dev_err(&pdev->dev, "failed to get PLL regulator: %d\n",
+ err);
+
+ return err;
}
hdmi->vdd = devm_regulator_get(&pdev->dev, "vdd");
--
2.14.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2018-08-14 12:54 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-14 12:53 [PATCH v2] drm/tegra: hdmi: probe deferral error reporting Marcel Ziswiler
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).