summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Langlais <philippe.langlais@linaro.org>2012-04-18 14:51:04 +0200
committerPhilippe Langlais <philippe.langlais@stericsson.com>2012-05-22 10:59:36 +0200
commit2ac6bfcf2afaae7e7033711b5264423a82f55994 (patch)
tree9ecdc54921da3ad6535dd3c5c257ebcc340ef1cd
parent4beb10c6332dfae9619a835a61f71d2b1437a21c (diff)
cpufreq: Porting ST-E cpufreq_ondemand changes onto new 3.4-rc3
Signed-off-by: Philippe Langlais <philippe.langlais@linaro.org>
-rw-r--r--drivers/cpufreq/cpufreq_ondemand.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/cpufreq/cpufreq_ondemand.c b/drivers/cpufreq/cpufreq_ondemand.c
index f160889a2df..765256e4904 100644
--- a/drivers/cpufreq/cpufreq_ondemand.c
+++ b/drivers/cpufreq/cpufreq_ondemand.c
@@ -291,22 +291,23 @@ static void update_sampling_rate(unsigned int new_rate)
mutex_lock(&dbs_info->timer_mutex);
- if (!delayed_work_pending(&dbs_info->work)) {
+ if (!delayed_work_pending(&per_cpu(ondemand_work, cpu))) {
mutex_unlock(&dbs_info->timer_mutex);
continue;
}
next_sampling = jiffies + usecs_to_jiffies(new_rate);
- appointed_at = dbs_info->work.timer.expires;
+ appointed_at = per_cpu(ondemand_work, cpu).timer.expires;
if (time_before(next_sampling, appointed_at)) {
mutex_unlock(&dbs_info->timer_mutex);
- cancel_delayed_work_sync(&dbs_info->work);
+ cancel_delayed_work_sync(&per_cpu(ondemand_work, cpu));
mutex_lock(&dbs_info->timer_mutex);
- schedule_delayed_work_on(dbs_info->cpu, &dbs_info->work,
+ schedule_delayed_work_on(dbs_info->cpu,
+ &per_cpu(ondemand_work, cpu),
usecs_to_jiffies(new_rate));
}