summaryrefslogtreecommitdiff
path: root/drivers/thermal
diff options
context:
space:
mode:
authorRam Chandrasekar <rkumbako@codeaurora.org>2017-02-01 10:57:36 -0700
committerRam Chandrasekar <rkumbako@codeaurora.org>2017-02-01 16:51:24 -0700
commit8b22d5db34cc5d1f06f77458104c405f0f68aecf (patch)
treef8d47dbfe118d6e69c6ac915ed2a734049210556 /drivers/thermal
parentaf883d4db0b398542bb561808a11019f0998d129 (diff)
msm: thermal: Apply frequency limit on online CPU to LMH DCVSh
KTM won't apply a frequency mitigation request for an offline cluster. Instead when the CPU is brought back online, the cpufreq will ask for new request and KTM will limit the frequency at that time. With the LMH DCVSh doing the frequency mitigation, the frequency request is not applied when the CPU comes back online. For targets with LMH DCVSh frequency mitigation, apply the latest frequency mitigation request when the CPU comes back online. Change-Id: If280e4e19fc5dd717aae4f0992d2e2950c057c57 Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
Diffstat (limited to 'drivers/thermal')
-rw-r--r--drivers/thermal/msm_thermal.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/thermal/msm_thermal.c b/drivers/thermal/msm_thermal.c
index f685892edd39..82ba412b864e 100644
--- a/drivers/thermal/msm_thermal.c
+++ b/drivers/thermal/msm_thermal.c
@@ -1,4 +1,4 @@
-/* Copyright (c) 2012-2016, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2012-2017, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
@@ -3554,6 +3554,12 @@ static int __ref msm_thermal_cpu_callback(struct notifier_block *nfb,
switch (action & ~CPU_TASKS_FROZEN) {
case CPU_UP_PREPARE:
+ /*
+ * Apply LMH freq cap vote, which was requested when the
+ * core was offline.
+ */
+ if (lmh_dcvs_available)
+ msm_lmh_dcvs_update(cpu);
if (!cpumask_test_and_set_cpu(cpu, cpus_previously_online))
pr_debug("Total prev cores online tracked %u\n",
cpumask_weight(cpus_previously_online));