|
|
|
|
|
|
|
|
|
|
xen-ia64-devel
[Xen-ia64-devel] [patch] don't dereference xen_start_info when running o
Hi,
On ia64 we don't create a xen_start_info when running on raw hardware
so the pointer is NULL. Doesn't work very well with the original
implementation of is_initial_xendomain() :-)
Cheers,
Jes
# HG changeset patch
# User jes@xxxxxxxxxxxxxxxx
# Date 1166546932 -3600
# Node ID 9411fcd9abdeb59fa5a2b3c3f54e1d0432d616c4
# Parent aabb5fba6a2e12beec379f24fe9ddd656d09c98f
Check we are running under Xen before trying to dereference
xen_start_info! xen_start_info is NULL on ia64 if running raw
hardware.
Signed-off-by: Jes Sorensen <jes@xxxxxxx>
diff -r aabb5fba6a2e -r 9411fcd9abde
linux-2.6-xen-sparse/include/asm-ia64/hypervisor.h
--- a/linux-2.6-xen-sparse/include/asm-ia64/hypervisor.h Tue Dec 19
12:36:12 2006 +0100
+++ b/linux-2.6-xen-sparse/include/asm-ia64/hypervisor.h Tue Dec 19
17:48:52 2006 +0100
@@ -215,7 +215,15 @@ asmlinkage int xprintk(const char *fmt,
#endif /* CONFIG_XEN || CONFIG_VMX_GUEST */
#ifdef CONFIG_XEN_PRIVILEGED_GUEST
-#define is_initial_xendomain() (xen_start_info->flags & SIF_INITDOMAIN)
+#define is_initial_xendomain() \
+({ \
+ int retval; \
+ if (is_running_on_xen()) \
+ retval = xen_start_info->flags & SIF_INITDOMAIN; \
+ else \
+ retval = 0; \
+ retval; \
+})
#else
#define is_initial_xendomain() 0
#endif
_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread>
|
- [Xen-ia64-devel] [patch] don't dereference xen_start_info when running on raw hardware,
Jes Sorensen <=
|
|
|
|
|