mirror of
https://github.com/adulau/aha.git
synced 2024-12-27 19:26:25 +00:00
[CPUFREQ] Do not set policy for offline cpus
Suspend/Resume fails on multi socket, multi core systems because the cpufreq code erroneously sets the per_cpu policy_cpu value when a logical cpu is offline. This most notably results in missing sysfs files that are used to set the cpu frequencies of the various cpus. Signed-off-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Dave Jones <davej@redhat.com>
This commit is contained in:
parent
26d204afa1
commit
42c74b84c6
1 changed files with 2 additions and 0 deletions
|
@ -924,6 +924,8 @@ static int cpufreq_add_dev(struct sys_device *sys_dev)
|
|||
|
||||
spin_lock_irqsave(&cpufreq_driver_lock, flags);
|
||||
for_each_cpu(j, policy->cpus) {
|
||||
if (!cpu_online(j))
|
||||
continue;
|
||||
per_cpu(cpufreq_cpu_data, j) = policy;
|
||||
per_cpu(policy_cpu, j) = policy->cpu;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue