diff options
Diffstat (limited to 'include/asm-x86/smp.h')
-rw-r--r-- | include/asm-x86/smp.h | 34 |
1 files changed, 26 insertions, 8 deletions
diff --git a/include/asm-x86/smp.h b/include/asm-x86/smp.h index 29324c103341..6df2615f9138 100644 --- a/include/asm-x86/smp.h +++ b/include/asm-x86/smp.h | |||
@@ -50,12 +50,16 @@ extern struct { | |||
50 | struct smp_ops { | 50 | struct smp_ops { |
51 | void (*smp_prepare_boot_cpu)(void); | 51 | void (*smp_prepare_boot_cpu)(void); |
52 | void (*smp_prepare_cpus)(unsigned max_cpus); | 52 | void (*smp_prepare_cpus)(unsigned max_cpus); |
53 | int (*cpu_up)(unsigned cpu); | ||
54 | void (*smp_cpus_done)(unsigned max_cpus); | 53 | void (*smp_cpus_done)(unsigned max_cpus); |
55 | 54 | ||
56 | void (*smp_send_stop)(void); | 55 | void (*smp_send_stop)(void); |
57 | void (*smp_send_reschedule)(int cpu); | 56 | void (*smp_send_reschedule)(int cpu); |
58 | 57 | ||
58 | int (*cpu_up)(unsigned cpu); | ||
59 | int (*cpu_disable)(void); | ||
60 | void (*cpu_die)(unsigned int cpu); | ||
61 | void (*play_dead)(void); | ||
62 | |||
59 | void (*send_call_func_ipi)(cpumask_t mask); | 63 | void (*send_call_func_ipi)(cpumask_t mask); |
60 | void (*send_call_func_single_ipi)(int cpu); | 64 | void (*send_call_func_single_ipi)(int cpu); |
61 | }; | 65 | }; |
@@ -94,6 +98,21 @@ static inline int __cpu_up(unsigned int cpu) | |||
94 | return smp_ops.cpu_up(cpu); | 98 | return smp_ops.cpu_up(cpu); |
95 | } | 99 | } |
96 | 100 | ||
101 | static inline int __cpu_disable(void) | ||
102 | { | ||
103 | return smp_ops.cpu_disable(); | ||
104 | } | ||
105 | |||
106 | static inline void __cpu_die(unsigned int cpu) | ||
107 | { | ||
108 | smp_ops.cpu_die(cpu); | ||
109 | } | ||
110 | |||
111 | static inline void play_dead(void) | ||
112 | { | ||
113 | smp_ops.play_dead(); | ||
114 | } | ||
115 | |||
97 | static inline void smp_send_reschedule(int cpu) | 116 | static inline void smp_send_reschedule(int cpu) |
98 | { | 117 | { |
99 | smp_ops.smp_send_reschedule(cpu); | 118 | smp_ops.smp_send_reschedule(cpu); |
@@ -109,16 +128,19 @@ static inline void arch_send_call_function_ipi(cpumask_t mask) | |||
109 | smp_ops.send_call_func_ipi(mask); | 128 | smp_ops.send_call_func_ipi(mask); |
110 | } | 129 | } |
111 | 130 | ||
131 | void cpu_disable_common(void); | ||
112 | void native_smp_prepare_boot_cpu(void); | 132 | void native_smp_prepare_boot_cpu(void); |
113 | void native_smp_prepare_cpus(unsigned int max_cpus); | 133 | void native_smp_prepare_cpus(unsigned int max_cpus); |
114 | void native_smp_cpus_done(unsigned int max_cpus); | 134 | void native_smp_cpus_done(unsigned int max_cpus); |
115 | int native_cpu_up(unsigned int cpunum); | 135 | int native_cpu_up(unsigned int cpunum); |
136 | int native_cpu_disable(void); | ||
137 | void native_cpu_die(unsigned int cpu); | ||
138 | void native_play_dead(void); | ||
139 | void play_dead_common(void); | ||
140 | |||
116 | void native_send_call_func_ipi(cpumask_t mask); | 141 | void native_send_call_func_ipi(cpumask_t mask); |
117 | void native_send_call_func_single_ipi(int cpu); | 142 | void native_send_call_func_single_ipi(int cpu); |
118 | 143 | ||
119 | extern int __cpu_disable(void); | ||
120 | extern void __cpu_die(unsigned int cpu); | ||
121 | |||
122 | void smp_store_cpu_info(int id); | 144 | void smp_store_cpu_info(int id); |
123 | #define cpu_physical_id(cpu) per_cpu(x86_cpu_to_apicid, cpu) | 145 | #define cpu_physical_id(cpu) per_cpu(x86_cpu_to_apicid, cpu) |
124 | 146 | ||
@@ -205,9 +227,5 @@ static inline int hard_smp_processor_id(void) | |||
205 | 227 | ||
206 | #endif /* CONFIG_X86_LOCAL_APIC */ | 228 | #endif /* CONFIG_X86_LOCAL_APIC */ |
207 | 229 | ||
208 | #ifdef CONFIG_HOTPLUG_CPU | ||
209 | extern void cpu_uninit(void); | ||
210 | #endif | ||
211 | |||
212 | #endif /* __ASSEMBLY__ */ | 230 | #endif /* __ASSEMBLY__ */ |
213 | #endif /* ASM_X86__SMP_H */ | 231 | #endif /* ASM_X86__SMP_H */ |