drm/exynos: dsi: Simplify with dev_err_probe()
Common pattern of handling deferred probe can be simplified with dev_err_probe(). Less code and also it prints the error value. Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Reviewed-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
This commit is contained in:

committed by
Inki Dae

parent
b40be05ed2
commit
73bb394cb9
@@ -1760,11 +1760,8 @@ static int exynos_dsi_probe(struct platform_device *pdev)
|
|||||||
dsi->supplies[1].supply = "vddio";
|
dsi->supplies[1].supply = "vddio";
|
||||||
ret = devm_regulator_bulk_get(dev, ARRAY_SIZE(dsi->supplies),
|
ret = devm_regulator_bulk_get(dev, ARRAY_SIZE(dsi->supplies),
|
||||||
dsi->supplies);
|
dsi->supplies);
|
||||||
if (ret) {
|
if (ret)
|
||||||
if (ret != -EPROBE_DEFER)
|
return dev_err_probe(dev, ret, "failed to get regulators\n");
|
||||||
dev_info(dev, "failed to get regulators: %d\n", ret);
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
dsi->clks = devm_kcalloc(dev,
|
dsi->clks = devm_kcalloc(dev,
|
||||||
dsi->driver_data->num_clks, sizeof(*dsi->clks),
|
dsi->driver_data->num_clks, sizeof(*dsi->clks),
|
||||||
|
Reference in New Issue
Block a user