opp: Fix early exit from dev_pm_opp_register_set_opp_helper()

We returned earlier by mistake even when there were no failures. Fix it.

Fixes: dd461cd918 ("opp: Allow dev_pm_opp_get_opp_table() to return -EPROBE_DEFER")
Reported-by: Naresh Kamboju <naresh.kamboju@linaro.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Tested-by: Naresh Kamboju <naresh.kamboju@linaro.com>
This commit is contained in:
Viresh Kumar 2020-10-20 16:03:15 +05:30
parent 1f6620f870
commit 47efcbcb34
1 changed files with 1 additions and 1 deletions

View File

@ -1930,7 +1930,7 @@ struct opp_table *dev_pm_opp_register_set_opp_helper(struct device *dev,
return ERR_PTR(-EINVAL);
opp_table = dev_pm_opp_get_opp_table(dev);
if (!IS_ERR(opp_table))
if (IS_ERR(opp_table))
return opp_table;
/* This should be called before OPPs are initialized */