mirror of
https://github.com/torvalds/linux.git
synced 2026-07-31 19:47:08 +02:00
cpufreq: qcom-hw: Reset cancel_throttle when policy is re-enabled
If LMH (Limits Management Hardware) is available, when a policy is
disabled by unplugging the last online CPU of policy->cpus,
qcom_cpufreq_hw_cpu_offline() sets cancel_throttle=true.
cancel_throttle is not reset when the policy is re-enabled with any
of the CPU in policy->cpus being plugged in. So reset it.
This patch also adds an early exit check.
Change-Id: Iea871695e574aed6037833086fee45b13da726c3
Signed-off-by: Pierre Gondois <pierre.gondois@arm.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Git-repo: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
Git-commit: cdcf8eb3e7
Signed-off-by: Mike Tipton <quic_mdtipton@quicinc.com>
This commit is contained in:
parent
be83eb2675
commit
8ce580d2f1
|
|
@ -518,6 +518,10 @@ static int qcom_cpufreq_hw_cpu_online(struct cpufreq_policy *policy)
|
|||
if (data->throttle_irq <= 0)
|
||||
return 0;
|
||||
|
||||
mutex_lock(&data->throttle_lock);
|
||||
data->cancel_throttle = false;
|
||||
mutex_unlock(&data->throttle_lock);
|
||||
|
||||
ret = irq_set_affinity_hint(data->throttle_irq, policy->cpus);
|
||||
if (ret)
|
||||
dev_err(&pdev->dev, "Failed to set CPU affinity of %s[%d]\n",
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user