[CPUFREQ] speedstep-centrino: fix SMP memory leak
Venkatesh Pallipadi made me aware of a memory leak in speedstep-centrino: centrino_model is allocated for all CPUs. There were two possibilities: either make the centrino_model data per-CPU, or to share it across CPUs. I chose the former variant, as ACPI data may be broken and/or different for multiple CPUs. Additionally, I made centrino_cpu per-CPU, and removed a check whether setting allowed_cpus to policy->cpus resulted in smp_processor_id() == policy->cpu: if policy->cpus has more than one bit set, this check will fail very often. Signed-off-by: Dominik Brodowski <linux@brodo.de> Signed-off-by: Dave Jones <davej@redhat.com>
Showing
Please register or sign in to comment