direct-io.hg

view linux-2.6-xen-sparse/include/xen/cpu_hotplug.h @ 11509:2e6c10dc7c0b

[POWERPC][XEN] make sure put_domain() is called in case of allocate_rma() failuer

Signed-off-by: Jimi Xenidis <jimix@watson.ibm.com>
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
author Jimi Xenidis <jimix@watson.ibm.com>
date Tue Sep 12 10:53:46 2006 -0400 (2006-09-12)
parents e58e04589d11
children e47738923a05
line source
1 #ifndef __XEN_CPU_HOTPLUG_H__
2 #define __XEN_CPU_HOTPLUG_H__
4 #include <linux/config.h>
5 #include <linux/kernel.h>
6 #include <linux/cpumask.h>
8 #if defined(CONFIG_HOTPLUG_CPU)
10 #if defined(CONFIG_X86)
11 void cpu_initialize_context(unsigned int cpu);
12 #else
13 #define cpu_initialize_context(cpu) ((void)0)
14 #endif
16 int cpu_up_check(unsigned int cpu);
17 void init_xenbus_allowed_cpumask(void);
18 int smp_suspend(void);
19 void smp_resume(void);
21 void cpu_bringup(void);
23 #else /* !defined(CONFIG_HOTPLUG_CPU) */
25 #define cpu_up_check(cpu) (0)
26 #define init_xenbus_allowed_cpumask() ((void)0)
28 static inline int smp_suspend(void)
29 {
30 if (num_online_cpus() > 1) {
31 printk(KERN_WARNING "Can't suspend SMP guests "
32 "without CONFIG_HOTPLUG_CPU\n");
33 return -EOPNOTSUPP;
34 }
35 return 0;
36 }
38 static inline void smp_resume(void)
39 {
40 }
42 #endif /* !defined(CONFIG_HOTPLUG_CPU) */
44 #endif /* __XEN_CPU_HOTPLUG_H__ */