Skip to content

Commit fa155f4

Browse files
ahalaneyvireshk
authored andcommitted
OPP: Use dev_err_probe() when failing to get icc_path
This, in tandem with dynamic debug, can print useful information about -EPROBE_DEFFER like below, and keeps similar behavior for other errors: [ 16.561072] cpu cpu0: error -EPROBE_DEFER: dev_pm_opp_of_find_icc_paths: Unable to get path0 [ 16.575777] platform 18591000.cpufreq: deferred probe pending Signed-off-by: Andrew Halaney <ahalaney@redhat.com> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
1 parent 7c41cdc commit fa155f4

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

drivers/opp/of.c

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -513,11 +513,7 @@ int dev_pm_opp_of_find_icc_paths(struct device *dev,
513513
for (i = 0; i < num_paths; i++) {
514514
paths[i] = of_icc_get_by_index(dev, i);
515515
if (IS_ERR(paths[i])) {
516-
ret = PTR_ERR(paths[i]);
517-
if (ret != -EPROBE_DEFER) {
518-
dev_err(dev, "%s: Unable to get path%d: %d\n",
519-
__func__, i, ret);
520-
}
516+
ret = dev_err_probe(dev, ret, "%s: Unable to get path%d\n", __func__, i);
521517
goto err;
522518
}
523519
}

0 commit comments

Comments
 (0)