diff options
author | Mike Travis <travis@sgi.com> | 2007-10-16 04:24:05 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-16 12:42:50 -0400 |
commit | d5a7430ddcdb598261d70f7eb1bf450b5be52085 (patch) | |
tree | 3b94672e0dbc2bff125de3266908f1a47a17b795 /arch/x86/xen/smp.c | |
parent | 083576112940fda783d716fd5ccc744f81667b2f (diff) |
Convert cpu_sibling_map to be a per cpu variable
Convert cpu_sibling_map from a static array sized by NR_CPUS to a per_cpu
variable. This saves sizeof(cpumask_t) * NR unused cpus. Access is mostly
from startup and CPU HOTPLUG functions.
Signed-off-by: Mike Travis <travis@sgi.com>
Cc: Andi Kleen <ak@suse.de>
Cc: Christoph Lameter <clameter@sgi.com>
Cc: "Siddha, Suresh B" <suresh.b.siddha@intel.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: "Luck, Tony" <tony.luck@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/x86/xen/smp.c')
-rw-r--r-- | arch/x86/xen/smp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/xen/smp.c b/arch/x86/xen/smp.c index 539d42530fc4..4fa33c27ccb6 100644 --- a/arch/x86/xen/smp.c +++ b/arch/x86/xen/smp.c | |||
@@ -147,7 +147,7 @@ void __init xen_smp_prepare_boot_cpu(void) | |||
147 | make_lowmem_page_readwrite(&per_cpu__gdt_page); | 147 | make_lowmem_page_readwrite(&per_cpu__gdt_page); |
148 | 148 | ||
149 | for (cpu = 0; cpu < NR_CPUS; cpu++) { | 149 | for (cpu = 0; cpu < NR_CPUS; cpu++) { |
150 | cpus_clear(cpu_sibling_map[cpu]); | 150 | cpus_clear(per_cpu(cpu_sibling_map, cpu)); |
151 | /* | 151 | /* |
152 | * cpu_core_map lives in a per cpu area that is cleared | 152 | * cpu_core_map lives in a per cpu area that is cleared |
153 | * when the per cpu array is allocated. | 153 | * when the per cpu array is allocated. |
@@ -164,7 +164,7 @@ void __init xen_smp_prepare_cpus(unsigned int max_cpus) | |||
164 | unsigned cpu; | 164 | unsigned cpu; |
165 | 165 | ||
166 | for (cpu = 0; cpu < NR_CPUS; cpu++) { | 166 | for (cpu = 0; cpu < NR_CPUS; cpu++) { |
167 | cpus_clear(cpu_sibling_map[cpu]); | 167 | cpus_clear(per_cpu(cpu_sibling_map, cpu)); |
168 | /* | 168 | /* |
169 | * cpu_core_ map will be zeroed when the per | 169 | * cpu_core_ map will be zeroed when the per |
170 | * cpu area is allocated. | 170 | * cpu area is allocated. |