mirror of
https://github.com/torvalds/linux.git
synced 2024-11-12 23:23:03 +00:00
pmdomain: qcom: cpr: Simplify with dev_err_probe()
Use dev_err_probe() to make defer code handling simpler. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Konrad Dybcio <konradybcio@kernel.org> Link: https://lore.kernel.org/r/20240823-cleanup-h-guard-pm-domain-v1-5-8320722eaf39@linaro.org Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
This commit is contained in:
parent
13bd778c90
commit
584dc41b3d
@ -1464,9 +1464,8 @@ static int cpr_pd_attach_dev(struct generic_pm_domain *domain,
|
||||
*/
|
||||
drv->cpu_clk = devm_clk_get(dev, NULL);
|
||||
if (IS_ERR(drv->cpu_clk)) {
|
||||
ret = PTR_ERR(drv->cpu_clk);
|
||||
if (ret != -EPROBE_DEFER)
|
||||
dev_err(drv->dev, "could not get cpu clk: %d\n", ret);
|
||||
ret = dev_err_probe(drv->dev, PTR_ERR(drv->cpu_clk),
|
||||
"could not get cpu clk\n");
|
||||
goto unlock;
|
||||
}
|
||||
drv->attached_cpu_dev = dev;
|
||||
|
Loading…
Reference in New Issue
Block a user