aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/module.c
diff options
context:
space:
mode:
authorJeremy Fitzhardinge <jeremy@goop.org>2007-05-02 13:27:11 -0400
committerAndi Kleen <andi@basil.nowhere.org>2007-05-02 13:27:11 -0400
commitb00742d399513a4100c24cc2accefdc1bb1e0b15 (patch)
tree57551a08eb218ed4aadb0a90806f33826df27f8a /kernel/module.c
parentbbba11c35baaad3f70f32e185a2c1d40d7901fe9 (diff)
[PATCH] x86-64: Account for module percpu space separately from kernel percpu
Rather than using a single constant PERCPU_ENOUGH_ROOM, compute it as the sum of kernel_percpu + PERCPU_MODULE_RESERVE. This is now common to all architectures; if an architecture wants to set PERCPU_ENOUGH_ROOM to something special, then it may do so (ia64 is the only one which does). Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com> Signed-off-by: Andi Kleen <ak@suse.de> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Eric W. Biederman <ebiederm@xmission.com> Cc: Andi Kleen <ak@suse.de>
Diffstat (limited to 'kernel/module.c')
-rw-r--r--kernel/module.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/module.c b/kernel/module.c
index 9da5af668a20..cf49ca25fcce 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -430,7 +430,7 @@ static int percpu_modinit(void)
430 pcpu_size = kmalloc(sizeof(pcpu_size[0]) * pcpu_num_allocated, 430 pcpu_size = kmalloc(sizeof(pcpu_size[0]) * pcpu_num_allocated,
431 GFP_KERNEL); 431 GFP_KERNEL);
432 /* Static in-kernel percpu data (used). */ 432 /* Static in-kernel percpu data (used). */
433 pcpu_size[0] = -ALIGN(__per_cpu_end-__per_cpu_start, SMP_CACHE_BYTES); 433 pcpu_size[0] = -(__per_cpu_end-__per_cpu_start);
434 /* Free room. */ 434 /* Free room. */
435 pcpu_size[1] = PERCPU_ENOUGH_ROOM + pcpu_size[0]; 435 pcpu_size[1] = PERCPU_ENOUGH_ROOM + pcpu_size[0];
436 if (pcpu_size[1] < 0) { 436 if (pcpu_size[1] < 0) {