diff options
Diffstat (limited to 'drivers/cpufreq/omap-cpufreq.c')
-rw-r--r-- | drivers/cpufreq/omap-cpufreq.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/cpufreq/omap-cpufreq.c b/drivers/cpufreq/omap-cpufreq.c index 17fa04d08be9..b47034e650a5 100644 --- a/drivers/cpufreq/omap-cpufreq.c +++ b/drivers/cpufreq/omap-cpufreq.c | |||
@@ -218,7 +218,7 @@ static int __cpuinit omap_cpu_init(struct cpufreq_policy *policy) | |||
218 | 218 | ||
219 | policy->cur = policy->min = policy->max = omap_getspeed(policy->cpu); | 219 | policy->cur = policy->min = policy->max = omap_getspeed(policy->cpu); |
220 | 220 | ||
221 | if (atomic_inc_return(&freq_table_users) == 1) | 221 | if (!freq_table) |
222 | result = opp_init_cpufreq_table(mpu_dev, &freq_table); | 222 | result = opp_init_cpufreq_table(mpu_dev, &freq_table); |
223 | 223 | ||
224 | if (result) { | 224 | if (result) { |
@@ -227,6 +227,8 @@ static int __cpuinit omap_cpu_init(struct cpufreq_policy *policy) | |||
227 | goto fail_ck; | 227 | goto fail_ck; |
228 | } | 228 | } |
229 | 229 | ||
230 | atomic_inc_return(&freq_table_users); | ||
231 | |||
230 | result = cpufreq_frequency_table_cpuinfo(policy, freq_table); | 232 | result = cpufreq_frequency_table_cpuinfo(policy, freq_table); |
231 | if (result) | 233 | if (result) |
232 | goto fail_table; | 234 | goto fail_table; |