From 12a9b84eee032198f33b911192f994ff1ac98e10 Mon Sep 17 00:00:00 2001 From: Pavankumar Kondeti Date: Wed, 14 Feb 2018 16:49:46 +0530 Subject: [PATCH] cpufreq: qcom-hw: Notify the current frequency to the topology driver The topology driver keeps track of the current capacity of a CPU and make it available via arch_scale_freq_capacity(). The PELT load tracking in the scheduler and energy-aware task placement are the clients of this API. Hence notify the new frequency to the topology driver during frequency transition. Change-Id: Ia0890956f59082496e7d5d7ba8a9c09b343e44ec Signed-off-by: Pavankumar Kondeti [satyap@codeaurora.org: resolve trivial merge conflict] Signed-off-by: Satya Durga Srinivasu Prabhala --- drivers/cpufreq/qcom-cpufreq-hw.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/cpufreq/qcom-cpufreq-hw.c b/drivers/cpufreq/qcom-cpufreq-hw.c index 86960e914b8c..fa217d5ac008 100644 --- a/drivers/cpufreq/qcom-cpufreq-hw.c +++ b/drivers/cpufreq/qcom-cpufreq-hw.c @@ -51,6 +51,9 @@ qcom_cpufreq_hw_target_index(struct cpufreq_policy *policy, struct cpufreq_qcom *c = policy->driver_data; writel_relaxed(index, c->reg_bases[REG_PERF_STATE]); + arch_set_freq_scale(policy->related_cpus, + policy->freq_table[index].frequency, + policy->cpuinfo.max_freq); return 0; }