summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorJunjie Wu <junjiew@codeaurora.org>2015-11-20 16:10:58 -0800
committerKyle Yan <kyan@codeaurora.org>2016-06-22 14:44:32 -0700
commitea6de85a0be106308347090b50e9da9363a0e8ca (patch)
treeb057586d9cc2528cc5d52f39ff2f84fcba9a1894 /drivers
parent384da356db5f3527e0f37a6182cd80605b4581d9 (diff)
qcom-cpufreq: Use cpufreq_table_validate_and_show to fill freq_table
cpufreq_table_validate_and_show() is created as a standard way to initialize frequency for a policy and assign freq_table. Use this new API to assign freq_table. CRs-Fixed: 1024229 Change-Id: Iac3a9394790e140492c5c0c0ad6d068840bfffa4 Signed-off-by: Junjie Wu <junjiew@codeaurora.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/cpufreq/qcom-cpufreq.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/cpufreq/qcom-cpufreq.c b/drivers/cpufreq/qcom-cpufreq.c
index 465198f34903..82861b1dbe46 100644
--- a/drivers/cpufreq/qcom-cpufreq.c
+++ b/drivers/cpufreq/qcom-cpufreq.c
@@ -143,8 +143,11 @@ static int msm_cpufreq_init(struct cpufreq_policy *policy)
if (cpu_clk[cpu] == cpu_clk[policy->cpu])
cpumask_set_cpu(cpu, policy->cpus);
- if (cpufreq_frequency_table_cpuinfo(policy, table))
+ ret = cpufreq_table_validate_and_show(policy, table);
+ if (ret) {
pr_err("cpufreq: failed to get policy min/max\n");
+ return ret;
+ }
cur_freq = clk_get_rate(cpu_clk[policy->cpu])/1000;
@@ -167,7 +170,6 @@ static int msm_cpufreq_init(struct cpufreq_policy *policy)
pr_debug("cpufreq: cpu%d init at %d switching to %d\n",
policy->cpu, cur_freq, table[index].frequency);
policy->cur = table[index].frequency;
- policy->freq_table = table;
return 0;
}