diff options
author | Ravikiran G Thirumalai <kiran@scalex86.org> | 2006-01-08 04:01:27 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-08 23:13:38 -0500 |
commit | 22fc6eccbf4ce4eb6265e6ada7b50a7b9cc57d05 (patch) | |
tree | 3887dc6f1eeb658d773be037971b98d6f5fb3dd7 /mm/sparse.c | |
parent | 6d524aed1f50b2b1d5b4ad5a4e2fe3f38106d0a6 (diff) |
[PATCH] Change maxaligned_in_smp alignemnt macros to internodealigned_in_smp macros
____cacheline_maxaligned_in_smp is currently used to align critical structures
and avoid false sharing. It uses per-arch L1_CACHE_SHIFT_MAX and people find
L1_CACHE_SHIFT_MAX useless.
However, we have been using ____cacheline_maxaligned_in_smp to align
structures on the internode cacheline size. As per Andi's suggestion,
following patch kills ____cacheline_maxaligned_in_smp and introduces
INTERNODE_CACHE_SHIFT, which defaults to L1_CACHE_SHIFT for all arches.
Arches needing L3/Internode cacheline alignment can define
INTERNODE_CACHE_SHIFT in the arch asm/cache.h. Patch replaces
____cacheline_maxaligned_in_smp with ____cacheline_internodealigned_in_smp
With this patch, L1_CACHE_SHIFT_MAX can be killed
Signed-off-by: Ravikiran Thirumalai <kiran@scalex86.org>
Signed-off-by: Shai Fultheim <shai@scalex86.org>
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm/sparse.c')
-rw-r--r-- | mm/sparse.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mm/sparse.c b/mm/sparse.c index 72079b538e2d..0a51f36ba3a1 100644 --- a/mm/sparse.c +++ b/mm/sparse.c | |||
@@ -18,10 +18,10 @@ | |||
18 | */ | 18 | */ |
19 | #ifdef CONFIG_SPARSEMEM_EXTREME | 19 | #ifdef CONFIG_SPARSEMEM_EXTREME |
20 | struct mem_section *mem_section[NR_SECTION_ROOTS] | 20 | struct mem_section *mem_section[NR_SECTION_ROOTS] |
21 | ____cacheline_maxaligned_in_smp; | 21 | ____cacheline_internodealigned_in_smp; |
22 | #else | 22 | #else |
23 | struct mem_section mem_section[NR_SECTION_ROOTS][SECTIONS_PER_ROOT] | 23 | struct mem_section mem_section[NR_SECTION_ROOTS][SECTIONS_PER_ROOT] |
24 | ____cacheline_maxaligned_in_smp; | 24 | ____cacheline_internodealigned_in_smp; |
25 | #endif | 25 | #endif |
26 | EXPORT_SYMBOL(mem_section); | 26 | EXPORT_SYMBOL(mem_section); |
27 | 27 | ||