aboutsummaryrefslogtreecommitdiffstats
path: root/xen/drivers/cpufreq
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2010-03-26 10:28:37 +0000
committerKeir Fraser <keir.fraser@citrix.com>2010-03-26 10:28:37 +0000
commitc530aaacc2319ccf64f89ef98b5e190ab85c7bcf (patch)
tree576da9d0e419c97479d124d7ac0b0069673edfb9 /xen/drivers/cpufreq
parent3915b8679abde33f5db3d1a7434a7545eab6d5e9 (diff)
downloadxen-c530aaacc2319ccf64f89ef98b5e190ab85c7bcf.tar.gz
xen-c530aaacc2319ccf64f89ef98b5e190ab85c7bcf.tar.bz2
xen-c530aaacc2319ccf64f89ef98b5e190ab85c7bcf.zip
cpufreq: don't re-init active dbs timer in S3 or cpu online
Signed-off-by: Wei Gang <gang.wei@intel.com>
Diffstat (limited to 'xen/drivers/cpufreq')
-rw-r--r--xen/drivers/cpufreq/cpufreq_ondemand.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/xen/drivers/cpufreq/cpufreq_ondemand.c b/xen/drivers/cpufreq/cpufreq_ondemand.c
index d4d43f4a34..5728a8fbaf 100644
--- a/xen/drivers/cpufreq/cpufreq_ondemand.c
+++ b/xen/drivers/cpufreq/cpufreq_ondemand.c
@@ -196,8 +196,9 @@ static void dbs_timer_init(struct cpu_dbs_info_s *dbs_info)
{
dbs_info->enable = 1;
- init_timer(&dbs_timer[dbs_info->cpu], do_dbs_timer,
- (void *)dbs_info, dbs_info->cpu);
+ if ( !dbs_timer[dbs_info->cpu].function )
+ init_timer(&dbs_timer[dbs_info->cpu], do_dbs_timer,
+ (void *)dbs_info, dbs_info->cpu);
set_timer(&dbs_timer[dbs_info->cpu], NOW()+dbs_tuners_ins.sampling_rate);