diff --git a/[refs] b/[refs] index 321aee7bd064..f997201ba0ed 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 226528c6100e4191842e61997110c8ace40605f7 +refs/heads/master: a665df9d510bfd5bac5664f436411f921471264a diff --git a/trunk/drivers/cpufreq/cpufreq_ondemand.c b/trunk/drivers/cpufreq/cpufreq_ondemand.c index fecfcdda6ddd..7b5093664e49 100644 --- a/trunk/drivers/cpufreq/cpufreq_ondemand.c +++ b/trunk/drivers/cpufreq/cpufreq_ondemand.c @@ -609,7 +609,9 @@ static void do_dbs_timer(struct work_struct *work) /* We want all CPUs to do sampling nearly on same jiffy */ int delay = usecs_to_jiffies(dbs_tuners_ins.sampling_rate); - delay -= jiffies % delay; + if (num_online_cpus() > 1) + delay -= jiffies % delay; + mutex_lock(&dbs_info->timer_mutex); /* Common NORMAL_SAMPLE setup */ @@ -634,7 +636,9 @@ static inline void dbs_timer_init(struct cpu_dbs_info_s *dbs_info) { /* We want all CPUs to do sampling nearly on same jiffy */ int delay = usecs_to_jiffies(dbs_tuners_ins.sampling_rate); - delay -= jiffies % delay; + + if (num_online_cpus() > 1) + delay -= jiffies % delay; dbs_info->sample_type = DBS_NORMAL_SAMPLE; INIT_DELAYED_WORK_DEFERRABLE(&dbs_info->work, do_dbs_timer);