]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blame - src/patches/suse-2.6.27.25/patches.fixes/numa-enable-hashdist-default.patch
Reenabled linux-xen and xen-image build
[people/pmueller/ipfire-2.x.git] / src / patches / suse-2.6.27.25 / patches.fixes / numa-enable-hashdist-default.patch
CommitLineData
00e5a55c
BS
1From: Anton Blanchard <anton@samba.org>
2Subject: mm: enable hashdist by default on 64bit NUMA
3References: bnc#501160
4Patch-upstream: yes
5Git: c2fdf3a9b2d52842808a8e551b53b55dd9b45030
6
7 mm: enable hashdist by default on 64bit NUMA
8
9 On PowerPC we allocate large boot time hashes on node 0. This leads to an
10 imbalance in the free memory, for example on a 64GB box (4 x 16GB nodes):
11
12 Free memory:
13 Node 0: 97.03%
14 Node 1: 98.54%
15 Node 2: 98.42%
16 Node 3: 98.53%
17
18 If we switch to using vmalloc (like ia64 and x86-64) things are more
19 balanced:
20
21 Free memory:
22 Node 0: 97.53%
23 Node 1: 98.35%
24 Node 2: 98.33%
25 Node 3: 98.33%
26
27 For many HPC applications we are limited by the free available memory on
28 the smallest node, so even though the same amount of memory is used the
29 better balancing helps.
30
31 Since all 64bit NUMA capable architectures should have sufficient vmalloc
32 space, it makes sense to enable it via CONFIG_64BIT.
33
34 Signed-off-by: Anton Blanchard <anton@samba.org>
35 Acked-by: David S. Miller <davem@davemloft.net>
36 Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
37 Acked-by: Ralf Baechle <ralf@linux-mips.org>
38 Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
39 Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
40 Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
41 Cc: Richard Henderson <rth@twiddle.net>
42 Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
43 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
44
45Acked-by: Nick Piggin <npiggin@suse.de>
46
47---
48 include/linux/bootmem.h | 6 +++---
49 1 file changed, 3 insertions(+), 3 deletions(-)
50
51--- a/include/linux/bootmem.h
52+++ b/include/linux/bootmem.h
53@@ -144,10 +144,10 @@ extern void *alloc_large_system_hash(con
54
55 #define HASH_EARLY 0x00000001 /* Allocating during early boot? */
56
57-/* Only NUMA needs hash distribution.
58- * IA64 and x86_64 have sufficient vmalloc space.
59+/* Only NUMA needs hash distribution. 64bit NUMA architectures have
60+ * sufficient vmalloc space.
61 */
62-#if defined(CONFIG_NUMA) && (defined(CONFIG_IA64) || defined(CONFIG_X86_64))
63+#if defined(CONFIG_NUMA) && defined(CONFIG_64BIT)
64 #define HASHDIST_DEFAULT 1
65 #else
66 #define HASHDIST_DEFAULT 0