summaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
diff options
context:
space:
mode:
authorMike Travis2009-01-01 03:08:47 +0100
committerIngo Molnar2009-01-03 19:15:40 +0100
commit80855f7361eb68205e6bc1981928629d9b02d5c9 (patch)
tree029e78df08989c8d335b67a8031c784136a57539 /arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
parentcpumask: convert shared_cpu_map in acpi_processor* structs to cpumask_var_t (diff)
downloadkernel-qcow2-linux-80855f7361eb68205e6bc1981928629d9b02d5c9.tar.gz
kernel-qcow2-linux-80855f7361eb68205e6bc1981928629d9b02d5c9.tar.xz
kernel-qcow2-linux-80855f7361eb68205e6bc1981928629d9b02d5c9.zip
cpumask: use alloc_cpumask_var_node where appropriate
Impact: Reduce inter-node memory traffic. Reduces inter-node memory traffic (offloading the global system bus) by allocating referenced struct cpumasks on the same node as the referring struct. Signed-off-by: Mike Travis <travis@sgi.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c')
-rw-r--r--arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c b/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
index d0a001093b2d..28102ad1a363 100644
--- a/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
+++ b/arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c
@@ -547,8 +547,9 @@ static int __init acpi_cpufreq_early_init(void)
return -ENOMEM;
}
for_each_possible_cpu(i) {
- if (!alloc_cpumask_var(&per_cpu_ptr(acpi_perf_data, i)
- ->shared_cpu_map, GFP_KERNEL)) {
+ if (!alloc_cpumask_var_node(
+ &per_cpu_ptr(acpi_perf_data, i)->shared_cpu_map,
+ GFP_KERNEL, cpu_to_node(i))) {
/* Freeing a NULL pointer is OK: alloc_percpu zeroes. */
free_acpi_perf_data();