cpufreq: imx6q: don't warn for disabling a non-existing frequency
authorChristoph Niedermaier <cniedermaier@dh-electronics.com>
Fri, 12 May 2023 15:07:11 +0000 (17:07 +0200)
committerViresh Kumar <viresh.kumar@linaro.org>
Mon, 15 May 2023 09:12:33 +0000 (14:42 +0530)
commit11a3b0ac33d95aa84be426e801f800997262a225
tree10e09ad65187af7c6e722d80a4a1c58753d20402
parentdcfce7c2cee481853e7717890e1e2d6daba354c4
cpufreq: imx6q: don't warn for disabling a non-existing frequency

It is confusing if a warning is given for disabling a non-existent
frequency of the operating performance points (OPP). In this case
the function dev_pm_opp_disable() returns -ENODEV. Check the return
value and avoid the output of a warning in this case. Avoid code
duplication by using a separate function.

Signed-off-by: Christoph Niedermaier <cniedermaier@dh-electronics.com>
[ Viresh : Updated commit subject ]
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
drivers/cpufreq/imx6q-cpufreq.c