aboutsummaryrefslogtreecommitdiffstats
path: root/linux-2.6-xen-sparse
diff options
context:
space:
mode:
authorkfraser@localhost.localdomain <kfraser@localhost.localdomain>2007-02-23 10:43:00 +0000
committerkfraser@localhost.localdomain <kfraser@localhost.localdomain>2007-02-23 10:43:00 +0000
commit2b1b3844b2392e06e91488612d5bc7976e3fb24b (patch)
treee6958f6f17ac360d6b37b156855ec8a24fde8af0 /linux-2.6-xen-sparse
parentaa700ae4e2f8ea4ff609362f79834bddc1567f64 (diff)
downloadxen-2b1b3844b2392e06e91488612d5bc7976e3fb24b.tar.gz
xen-2b1b3844b2392e06e91488612d5bc7976e3fb24b.tar.bz2
xen-2b1b3844b2392e06e91488612d5bc7976e3fb24b.zip
linux: Fix current_vcpu_info for UP case
Under !CONFIG_SMP, smp.h is not always included and hence smp_processor_id() not always visible. Signed-off-by: Jan Beulich <jbeulich@novell.com>
Diffstat (limited to 'linux-2.6-xen-sparse')
-rw-r--r--linux-2.6-xen-sparse/include/asm-i386/mach-xen/asm/hypervisor.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/linux-2.6-xen-sparse/include/asm-i386/mach-xen/asm/hypervisor.h b/linux-2.6-xen-sparse/include/asm-i386/mach-xen/asm/hypervisor.h
index ffe031b601..1690e2dc33 100644
--- a/linux-2.6-xen-sparse/include/asm-i386/mach-xen/asm/hypervisor.h
+++ b/linux-2.6-xen-sparse/include/asm-i386/mach-xen/asm/hypervisor.h
@@ -57,7 +57,11 @@
extern shared_info_t *HYPERVISOR_shared_info;
#define vcpu_info(cpu) (HYPERVISOR_shared_info->vcpu_info + (cpu))
+#ifdef CONFIG_SMP
#define current_vcpu_info() vcpu_info(smp_processor_id())
+#else
+#define current_vcpu_info() vcpu_info(0)
+#endif
#ifdef CONFIG_X86_32
extern unsigned long hypervisor_virt_start;