debuggers.hg

changeset 22834:5852612cd4c4

x86_32: Assert map_domian_page() not used too early.

Signed-off-by: Fengzhe Zhang <fengzhe.zhang@intel.com>
author Keir Fraser <keir@xen.org>
date Fri Jan 21 15:57:18 2011 +0000 (2011-01-21)
parents 003acf02d416
children 9bd5f65050f8
files xen/arch/x86/x86_32/domain_page.c
line diff
     1.1 --- a/xen/arch/x86/x86_32/domain_page.c	Thu Jan 20 17:04:06 2011 +0000
     1.2 +++ b/xen/arch/x86/x86_32/domain_page.c	Fri Jan 21 15:57:18 2011 +0000
     1.3 @@ -53,6 +53,8 @@ void *map_domain_page(unsigned long mfn)
     1.4      perfc_incr(map_domain_page_count);
     1.5  
     1.6      v = mapcache_current_vcpu();
     1.7 +    /* Prevent vcpu pointer being used before initialize. */
     1.8 +    ASSERT((unsigned long)v != 0xfffff000);
     1.9  
    1.10      dcache = &v->domain->arch.mapcache;
    1.11      vcache = &v->arch.mapcache;