summaryrefslogtreecommitdiff
path: root/sound/soc/img/img-spdif-out.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/img/img-spdif-out.c')
-rw-r--r--sound/soc/img/img-spdif-out.c24
1 files changed, 9 insertions, 15 deletions
diff --git a/sound/soc/img/img-spdif-out.c b/sound/soc/img/img-spdif-out.c
index 858e1b853820..c3189d9ff72f 100644
--- a/sound/soc/img/img-spdif-out.c
+++ b/sound/soc/img/img-spdif-out.c
@@ -342,25 +342,19 @@ static int img_spdif_out_probe(struct platform_device *pdev)
spdif->base = base;
spdif->rst = devm_reset_control_get_exclusive(&pdev->dev, "rst");
- if (IS_ERR(spdif->rst)) {
- if (PTR_ERR(spdif->rst) != -EPROBE_DEFER)
- dev_err(&pdev->dev, "No top level reset found\n");
- return PTR_ERR(spdif->rst);
- }
+ if (IS_ERR(spdif->rst))
+ return dev_err_probe(&pdev->dev, PTR_ERR(spdif->rst),
+ "No top level reset found\n");
spdif->clk_sys = devm_clk_get(&pdev->dev, "sys");
- if (IS_ERR(spdif->clk_sys)) {
- if (PTR_ERR(spdif->clk_sys) != -EPROBE_DEFER)
- dev_err(dev, "Failed to acquire clock 'sys'\n");
- return PTR_ERR(spdif->clk_sys);
- }
+ if (IS_ERR(spdif->clk_sys))
+ return dev_err_probe(dev, PTR_ERR(spdif->clk_sys),
+ "Failed to acquire clock 'sys'\n");
spdif->clk_ref = devm_clk_get(&pdev->dev, "ref");
- if (IS_ERR(spdif->clk_ref)) {
- if (PTR_ERR(spdif->clk_ref) != -EPROBE_DEFER)
- dev_err(dev, "Failed to acquire clock 'ref'\n");
- return PTR_ERR(spdif->clk_ref);
- }
+ if (IS_ERR(spdif->clk_ref))
+ return dev_err_probe(dev, PTR_ERR(spdif->clk_ref),
+ "Failed to acquire clock 'ref'\n");
pm_runtime_enable(&pdev->dev);
if (!pm_runtime_enabled(&pdev->dev)) {