Skip to content

Commit 201f371

Browse files
bzolnierrafaeljw
authored andcommitted
cpufreq: allow cpufreq_generic_suspend() to work without suspend frequency
Some cpufreq drivers may set suspend frequency only for selected setups but still would like to use the generic suspend handler. Thus don't treat !policy->suspend_freq condition as an incorrect one. Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent d9df93e commit 201f371

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/cpufreq/cpufreq.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1628,8 +1628,8 @@ int cpufreq_generic_suspend(struct cpufreq_policy *policy)
16281628
int ret;
16291629

16301630
if (!policy->suspend_freq) {
1631-
pr_err("%s: suspend_freq can't be zero\n", __func__);
1632-
return -EINVAL;
1631+
pr_debug("%s: suspend_freq not defined\n", __func__);
1632+
return 0;
16331633
}
16341634

16351635
pr_debug("%s: Setting suspend-freq: %u\n", __func__,

0 commit comments

Comments
 (0)