diff options
author | Viresh Kumar <viresh.kumar@linaro.org> | 2018-10-03 15:22:03 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-11-24 08:20:06 +0100 |
commit | 216929d15b2c655d960d72b6e76e1c744870a729 (patch) | |
tree | 77f4b25adb7d4875f76ad1aad78e471372e633a9 /drivers/opp | |
parent | 3d0c72f99efcbe7645c6490e81a4dc0acf53adcb (diff) | |
download | linux-stable-216929d15b2c655d960d72b6e76e1c744870a729.tar.gz linux-stable-216929d15b2c655d960d72b6e76e1c744870a729.tar.bz2 linux-stable-216929d15b2c655d960d72b6e76e1c744870a729.zip |
OPP: Return error on error from dev_pm_opp_get_opp_count()
[ Upstream commit 09f662f95306f3e3d47ab6842bc4b0bb868a80ad ]
Return error number instead of 0 on failures.
Fixes: a1e8c13600bf ("PM / OPP: "opp-hz" is optional for power domains")
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/opp')
-rw-r--r-- | drivers/opp/core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/opp/core.c b/drivers/opp/core.c index f3433bf47b10..1e80f9ec1aa6 100644 --- a/drivers/opp/core.c +++ b/drivers/opp/core.c @@ -313,7 +313,7 @@ int dev_pm_opp_get_opp_count(struct device *dev) count = PTR_ERR(opp_table); dev_dbg(dev, "%s: OPP table not found (%d)\n", __func__, count); - return 0; + return count; } count = _get_opp_count(opp_table); |