]> git.ipfire.org Git - ipfire-2.x.git/blob - src/patches/suse-2.6.27.31/patches.xen/xen3-x86_sgi_cpus4096-02-fix-send_call_func_ip.patch
Disable build of xen kernel.
[ipfire-2.x.git] / src / patches / suse-2.6.27.31 / patches.xen / xen3-x86_sgi_cpus4096-02-fix-send_call_func_ip.patch
1 From: Mike Travis <travis@sgi.com>
2 Date: Fri, 5 Sep 2008 14:40:21 -0700
3 Subject: [PATCH] x86: reduce stack requirements for send_call_func_ipi
4 References: bnc#425240 FATE304266
5 Patch-mainline: 2.6.28
6
7 * By converting the internal x86 smp_ops function send_call_func_ipi
8 to pass a pointer to the cpumask_t variable, we greatly reduce the
9 stack space required when NR_CPUS=4096.
10
11 Further reduction will be realized when the send_IPI_mask interface
12 is changed in 2.6.28.
13
14 Signed-off-by: Mike Travis <travis@sgi.com>
15 Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 Signed-off-by: Jiri Slaby <jslaby@suse.cz>
17 Signed-off-by: Thomas Renninger <trenn@suse.de>
18 Automatically created from "patches.arch/x86_sgi_cpus4096-02-fix-send_call_func_ip.patch" by xen-port-patches.py
19
20 Index: head-2008-11-04/arch/x86/kernel/smp-xen.c
21 ===================================================================
22 --- head-2008-11-04.orig/arch/x86/kernel/smp-xen.c 2008-11-04 11:55:22.000000000 +0100
23 +++ head-2008-11-04/arch/x86/kernel/smp-xen.c 2008-11-04 11:59:11.000000000 +0100
24 @@ -126,9 +126,9 @@ void xen_send_call_func_single_ipi(int c
25 send_IPI_mask(cpumask_of_cpu(cpu), CALL_FUNC_SINGLE_VECTOR);
26 }
27
28 -void xen_send_call_func_ipi(cpumask_t mask)
29 +void xen_send_call_func_ipi(const cpumask_t *mask)
30 {
31 - send_IPI_mask(mask, CALL_FUNCTION_VECTOR);
32 + send_IPI_mask(*mask, CALL_FUNCTION_VECTOR);
33 }
34
35 static void stop_this_cpu(void *dummy)
36 Index: head-2008-11-04/include/asm-x86/mach-xen/asm/smp.h
37 ===================================================================
38 --- head-2008-11-04.orig/include/asm-x86/mach-xen/asm/smp.h 2008-11-04 11:55:22.000000000 +0100
39 +++ head-2008-11-04/include/asm-x86/mach-xen/asm/smp.h 2008-11-04 14:07:28.000000000 +0100
40 @@ -57,7 +57,7 @@ struct smp_ops {
41 void (*smp_send_stop)(void);
42 void (*smp_send_reschedule)(int cpu);
43
44 - void (*send_call_func_ipi)(cpumask_t mask);
45 + void (*send_call_func_ipi)(const cpumask_t *mask);
46 void (*send_call_func_single_ipi)(int cpu);
47 };
48
49 @@ -106,7 +106,7 @@ static inline void arch_send_call_functi
50
51 static inline void arch_send_call_function_ipi(cpumask_t mask)
52 {
53 - smp_ops.send_call_func_ipi(mask);
54 + smp_ops.send_call_func_ipi(&mask);
55 }
56
57 void native_smp_prepare_boot_cpu(void);
58 @@ -118,13 +118,13 @@ int native_cpu_up(unsigned int cpunum);
59
60 void xen_smp_send_stop(void);
61 void xen_smp_send_reschedule(int cpu);
62 -void xen_send_call_func_ipi(cpumask_t mask);
63 +void xen_send_call_func_ipi(const cpumask_t *mask);
64 void xen_send_call_func_single_ipi(int cpu);
65
66 #define smp_send_stop xen_smp_send_stop
67 #define smp_send_reschedule xen_smp_send_reschedule
68 #define arch_send_call_function_single_ipi xen_send_call_func_single_ipi
69 -#define arch_send_call_function_ipi xen_send_call_func_ipi
70 +#define arch_send_call_function_ipi(m) xen_send_call_func_ipi(&(m))
71
72 #endif /* CONFIG_XEN */
73