diff options
Diffstat (limited to 'drivers/cpufreq/cpufreq_ondemand.c')
-rw-r--r-- | drivers/cpufreq/cpufreq_ondemand.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/drivers/cpufreq/cpufreq_ondemand.c b/drivers/cpufreq/cpufreq_ondemand.c index d6ba14276bb1..d7a528c80de8 100644 --- a/drivers/cpufreq/cpufreq_ondemand.c +++ b/drivers/cpufreq/cpufreq_ondemand.c | |||
@@ -78,7 +78,7 @@ struct cpu_dbs_info_s { | |||
78 | */ | 78 | */ |
79 | struct mutex timer_mutex; | 79 | struct mutex timer_mutex; |
80 | }; | 80 | }; |
81 | static DEFINE_PER_CPU(struct cpu_dbs_info_s, cpu_dbs_info); | 81 | static DEFINE_PER_CPU(struct cpu_dbs_info_s, od_cpu_dbs_info); |
82 | 82 | ||
83 | static unsigned int dbs_enable; /* number of CPUs using this policy */ | 83 | static unsigned int dbs_enable; /* number of CPUs using this policy */ |
84 | 84 | ||
@@ -149,7 +149,8 @@ static unsigned int powersave_bias_target(struct cpufreq_policy *policy, | |||
149 | unsigned int freq_hi, freq_lo; | 149 | unsigned int freq_hi, freq_lo; |
150 | unsigned int index = 0; | 150 | unsigned int index = 0; |
151 | unsigned int jiffies_total, jiffies_hi, jiffies_lo; | 151 | unsigned int jiffies_total, jiffies_hi, jiffies_lo; |
152 | struct cpu_dbs_info_s *dbs_info = &per_cpu(cpu_dbs_info, policy->cpu); | 152 | struct cpu_dbs_info_s *dbs_info = &per_cpu(od_cpu_dbs_info, |
153 | policy->cpu); | ||
153 | 154 | ||
154 | if (!dbs_info->freq_table) { | 155 | if (!dbs_info->freq_table) { |
155 | dbs_info->freq_lo = 0; | 156 | dbs_info->freq_lo = 0; |
@@ -192,7 +193,7 @@ static unsigned int powersave_bias_target(struct cpufreq_policy *policy, | |||
192 | 193 | ||
193 | static void ondemand_powersave_bias_init_cpu(int cpu) | 194 | static void ondemand_powersave_bias_init_cpu(int cpu) |
194 | { | 195 | { |
195 | struct cpu_dbs_info_s *dbs_info = &per_cpu(cpu_dbs_info, cpu); | 196 | struct cpu_dbs_info_s *dbs_info = &per_cpu(od_cpu_dbs_info, cpu); |
196 | dbs_info->freq_table = cpufreq_frequency_get_table(cpu); | 197 | dbs_info->freq_table = cpufreq_frequency_get_table(cpu); |
197 | dbs_info->freq_lo = 0; | 198 | dbs_info->freq_lo = 0; |
198 | } | 199 | } |
@@ -297,7 +298,7 @@ static ssize_t store_ignore_nice_load(struct cpufreq_policy *policy, | |||
297 | /* we need to re-evaluate prev_cpu_idle */ | 298 | /* we need to re-evaluate prev_cpu_idle */ |
298 | for_each_online_cpu(j) { | 299 | for_each_online_cpu(j) { |
299 | struct cpu_dbs_info_s *dbs_info; | 300 | struct cpu_dbs_info_s *dbs_info; |
300 | dbs_info = &per_cpu(cpu_dbs_info, j); | 301 | dbs_info = &per_cpu(od_cpu_dbs_info, j); |
301 | dbs_info->prev_cpu_idle = get_cpu_idle_time(j, | 302 | dbs_info->prev_cpu_idle = get_cpu_idle_time(j, |
302 | &dbs_info->prev_cpu_wall); | 303 | &dbs_info->prev_cpu_wall); |
303 | if (dbs_tuners_ins.ignore_nice) | 304 | if (dbs_tuners_ins.ignore_nice) |
@@ -388,7 +389,7 @@ static void dbs_check_cpu(struct cpu_dbs_info_s *this_dbs_info) | |||
388 | unsigned int load, load_freq; | 389 | unsigned int load, load_freq; |
389 | int freq_avg; | 390 | int freq_avg; |
390 | 391 | ||
391 | j_dbs_info = &per_cpu(cpu_dbs_info, j); | 392 | j_dbs_info = &per_cpu(od_cpu_dbs_info, j); |
392 | 393 | ||
393 | cur_idle_time = get_cpu_idle_time(j, &cur_wall_time); | 394 | cur_idle_time = get_cpu_idle_time(j, &cur_wall_time); |
394 | 395 | ||
@@ -535,7 +536,7 @@ static int cpufreq_governor_dbs(struct cpufreq_policy *policy, | |||
535 | unsigned int j; | 536 | unsigned int j; |
536 | int rc; | 537 | int rc; |
537 | 538 | ||
538 | this_dbs_info = &per_cpu(cpu_dbs_info, cpu); | 539 | this_dbs_info = &per_cpu(od_cpu_dbs_info, cpu); |
539 | 540 | ||
540 | switch (event) { | 541 | switch (event) { |
541 | case CPUFREQ_GOV_START: | 542 | case CPUFREQ_GOV_START: |
@@ -553,7 +554,7 @@ static int cpufreq_governor_dbs(struct cpufreq_policy *policy, | |||
553 | dbs_enable++; | 554 | dbs_enable++; |
554 | for_each_cpu(j, policy->cpus) { | 555 | for_each_cpu(j, policy->cpus) { |
555 | struct cpu_dbs_info_s *j_dbs_info; | 556 | struct cpu_dbs_info_s *j_dbs_info; |
556 | j_dbs_info = &per_cpu(cpu_dbs_info, j); | 557 | j_dbs_info = &per_cpu(od_cpu_dbs_info, j); |
557 | j_dbs_info->cur_policy = policy; | 558 | j_dbs_info->cur_policy = policy; |
558 | 559 | ||
559 | j_dbs_info->prev_cpu_idle = get_cpu_idle_time(j, | 560 | j_dbs_info->prev_cpu_idle = get_cpu_idle_time(j, |