[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] x86_32: Assert map_domian_page() not used too early.



# HG changeset patch
# User Keir Fraser <keir@xxxxxxx>
# Date 1295625438 0
# Node ID 5852612cd4c461e5219db73cc52de0c643c414e8
# Parent  003acf02d416d657f750b7a7748fa8c5a932222c
x86_32: Assert map_domian_page() not used too early.

Signed-off-by: Fengzhe Zhang <fengzhe.zhang@xxxxxxxxx>
---
 xen/arch/x86/x86_32/domain_page.c |    2 ++
 1 files changed, 2 insertions(+)

diff -r 003acf02d416 -r 5852612cd4c4 xen/arch/x86/x86_32/domain_page.c
--- a/xen/arch/x86/x86_32/domain_page.c Thu Jan 20 17:04:06 2011 +0000
+++ b/xen/arch/x86/x86_32/domain_page.c Fri Jan 21 15:57:18 2011 +0000
@@ -53,6 +53,8 @@ void *map_domain_page(unsigned long mfn)
     perfc_incr(map_domain_page_count);
 
     v = mapcache_current_vcpu();
+    /* Prevent vcpu pointer being used before initialize. */
+    ASSERT((unsigned long)v != 0xfffff000);
 
     dcache = &v->domain->arch.mapcache;
     vcache = &v->arch.mapcache;

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.