ia64/xen-unstable

changeset 19507:1f705f0a32e2

x86_64: explicitly zero CR[1] in getvcpucontext for guests with no user PT

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
author Keir Fraser <keir.fraser@citrix.com>
date Mon Apr 06 13:56:35 2009 +0100 (2009-04-06)
parents 3fecb8f43617
children ce8f37efc992
files xen/arch/x86/domctl.c
line diff
     1.1 --- a/xen/arch/x86/domctl.c	Mon Apr 06 13:52:56 2009 +0100
     1.2 +++ b/xen/arch/x86/domctl.c	Mon Apr 06 13:56:35 2009 +0100
     1.3 @@ -1161,9 +1161,9 @@ void arch_get_info_guest(struct vcpu *v,
     1.4              c.nat->ctrlreg[3] = xen_pfn_to_cr3(
     1.5                  pagetable_get_pfn(v->arch.guest_table));
     1.6  #ifdef __x86_64__
     1.7 -            if ( !pagetable_is_null(v->arch.guest_table_user) )
     1.8 -                c.nat->ctrlreg[1] = xen_pfn_to_cr3(
     1.9 -                    pagetable_get_pfn(v->arch.guest_table_user));
    1.10 +            c.nat->ctrlreg[1] =
    1.11 +                pagetable_is_null(v->arch.guest_table_user) ? 0
    1.12 +                : xen_pfn_to_cr3(pagetable_get_pfn(v->arch.guest_table_user));
    1.13  #endif
    1.14  
    1.15              /* Merge shadow DR7 bits into real DR7. */