summaryrefslogtreecommitdiffstats
path: root/drivers/cpufreq/sparc-us2e-cpufreq.c
diff options
context:
space:
mode:
authorViresh Kumar <viresh.kumar@linaro.org>2014-03-10 05:23:33 -0400
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2014-03-11 20:06:00 -0400
commite0b3165ba521c6824b3e9f563f38a701dfa2d8e6 (patch)
treec933f6ecc241a38c2e56f1b166c8c66d1635540c /drivers/cpufreq/sparc-us2e-cpufreq.c
parente837f9b58b83a705c9c14b26c3ee29fd9870322e (diff)
cpufreq: add 'freq_table' in struct cpufreq_policy
freq table is not per CPU but per policy, so it makes more sense to keep it within struct cpufreq_policy instead of a per-cpu variable. This patch does it. Over that, there is no need to set policy->freq_table to NULL in ->exit(), as policy structure is going to be freed soon. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/cpufreq/sparc-us2e-cpufreq.c')
-rw-r--r--drivers/cpufreq/sparc-us2e-cpufreq.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/cpufreq/sparc-us2e-cpufreq.c b/drivers/cpufreq/sparc-us2e-cpufreq.c
index 62aa23e219d4..b73feeb666f9 100644
--- a/drivers/cpufreq/sparc-us2e-cpufreq.c
+++ b/drivers/cpufreq/sparc-us2e-cpufreq.c
@@ -301,10 +301,8 @@ static int __init us2e_freq_cpu_init(struct cpufreq_policy *policy)
301 301
302static int us2e_freq_cpu_exit(struct cpufreq_policy *policy) 302static int us2e_freq_cpu_exit(struct cpufreq_policy *policy)
303{ 303{
304 if (cpufreq_us2e_driver) { 304 if (cpufreq_us2e_driver)
305 cpufreq_frequency_table_put_attr(policy->cpu);
306 us2e_freq_target(policy, 0); 305 us2e_freq_target(policy, 0);
307 }
308 306
309 return 0; 307 return 0;
310} 308}