From cdf324413b9ba1124ee241c8e30d04db6632d04b Mon Sep 17 00:00:00 2001 From: Bai Ping Date: Thu, 7 Apr 2016 18:05:08 +0800 Subject: [PATCH] MLK-12868-01 cpufreq: imx: get old_freq from policy->cur Get the old_freq from the policy->cur. Signed-off-by: Bai Ping --- drivers/cpufreq/imx6q-cpufreq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/cpufreq/imx6q-cpufreq.c b/drivers/cpufreq/imx6q-cpufreq.c index de33a1e5a054..fd2297e83b68 100644 --- a/drivers/cpufreq/imx6q-cpufreq.c +++ b/drivers/cpufreq/imx6q-cpufreq.c @@ -64,7 +64,7 @@ static int imx6q_set_target(struct cpufreq_policy *policy, unsigned int index) new_freq = freq_table[index].frequency; freq_hz = new_freq * 1000; - old_freq = clk_get_rate(arm_clk) / 1000; + old_freq = policy->cur; rcu_read_lock(); opp = dev_pm_opp_find_freq_ceil(cpu_dev, &freq_hz); -- 2.17.1