summaryrefslogtreecommitdiffstats
path: root/drivers/cpufreq/spear-cpufreq.c
diff options
context:
space:
mode:
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>2014-01-14 23:12:08 +0100
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2014-01-14 23:12:08 +0100
commit51c4c4ce1df49b14bbfc334c6388cc9efe32c631 (patch)
treeb33a9a905b9b646c78be7df7c189e7f9c0f28f77 /drivers/cpufreq/spear-cpufreq.c
parent6cbd7ee10e2842a3d1f9b60abede1c8f3d1f1130 (diff)
parent22c73795b101597051924556dce019385a1e2fa0 (diff)
downloadtalos-op-linux-51c4c4ce1df49b14bbfc334c6388cc9efe32c631.tar.gz
talos-op-linux-51c4c4ce1df49b14bbfc334c6388cc9efe32c631.zip
Merge back earlier 'pm-cpufreq' material.
Diffstat (limited to 'drivers/cpufreq/spear-cpufreq.c')
-rw-r--r--drivers/cpufreq/spear-cpufreq.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/cpufreq/spear-cpufreq.c b/drivers/cpufreq/spear-cpufreq.c
index d02ccd19c9c4..c7525fe33407 100644
--- a/drivers/cpufreq/spear-cpufreq.c
+++ b/drivers/cpufreq/spear-cpufreq.c
@@ -138,7 +138,7 @@ static int spear_cpufreq_target(struct cpufreq_policy *policy,
}
newfreq = clk_round_rate(srcclk, newfreq * mult);
- if (newfreq < 0) {
+ if (newfreq <= 0) {
pr_err("clk_round_rate failed for cpu src clock\n");
return newfreq;
}
@@ -162,7 +162,7 @@ static int spear_cpufreq_init(struct cpufreq_policy *policy)
static struct cpufreq_driver spear_cpufreq_driver = {
.name = "cpufreq-spear",
- .flags = CPUFREQ_STICKY,
+ .flags = CPUFREQ_STICKY | CPUFREQ_NEED_INITIAL_FREQ_CHECK,
.verify = cpufreq_generic_frequency_table_verify,
.target_index = spear_cpufreq_target,
.get = spear_cpufreq_get,
OpenPOWER on IntegriCloud