ia64/xen-unstable

changeset 10798:7137825805c7

[SVM] Correct compile time compare of CONFIG_PAGING_LEVELS for 64bit and
32bit PAE guests. This code affects accesses to the CR4 register by the SVM guest.

Signed-off-by: Tom Woller <thomas.woller@amd.com>
author kfraser@localhost.localdomain
date Wed Jul 26 11:10:26 2006 +0100 (2006-07-26)
parents 765654a55245
children 9b7e1ea4c4d2
files xen/arch/x86/hvm/svm/svm.c
line diff
     1.1 --- a/xen/arch/x86/hvm/svm/svm.c	Wed Jul 26 10:52:14 2006 +0100
     1.2 +++ b/xen/arch/x86/hvm/svm/svm.c	Wed Jul 26 11:10:26 2006 +0100
     1.3 @@ -1766,7 +1766,7 @@ static int mov_to_cr(int gpreg, int cr, 
     1.4              if ( svm_pgbit_test(v) )
     1.5              {
     1.6                  /* The guest is a 32-bit PAE guest. */
     1.7 -#if CONFIG_PAGING_LEVELS >= 4
     1.8 +#if CONFIG_PAGING_LEVELS >= 3
     1.9                  unsigned long mfn, old_base_mfn;
    1.10  
    1.11                  if( !shadow_set_guest_paging_levels(v->domain, PAGING_L3) )
    1.12 @@ -1810,7 +1810,7 @@ static int mov_to_cr(int gpreg, int cr, 
    1.13              else
    1.14              {
    1.15                  /*  The guest is a 64 bit or 32-bit PAE guest. */
    1.16 -#if CONFIG_PAGING_LEVELS >= 4
    1.17 +#if CONFIG_PAGING_LEVELS >= 3
    1.18                  if ( (v->domain->arch.ops != NULL) &&
    1.19                          v->domain->arch.ops->guest_paging_levels == PAGING_L2)
    1.20                  {