ia64/xen-unstable

changeset 16727:f17b34df974f

amd hvm (svm): Print warning if NPT constraints on PAE are hit.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
author Keir Fraser <keir.fraser@citrix.com>
date Wed Jan 16 15:55:57 2008 +0000 (2008-01-16)
parents ec3f90599ab1
children be960a84e492
files xen/arch/x86/mm/p2m.c xen/include/asm-x86/hvm/domain.h
line diff
     1.1 --- a/xen/arch/x86/mm/p2m.c	Wed Jan 16 13:44:18 2008 +0000
     1.2 +++ b/xen/arch/x86/mm/p2m.c	Wed Jan 16 15:55:57 2008 +0000
     1.3 @@ -701,12 +701,19 @@ guest_physmap_add_entry(struct domain *d
     1.4          return -EINVAL;
     1.5  
     1.6  #if CONFIG_PAGING_LEVELS == 3
     1.7 -    /* 32bit PAE nested paging does not support over 4GB guest due to 
     1.8 +    /*
     1.9 +     * 32bit PAE nested paging does not support over 4GB guest due to 
    1.10       * hardware translation limit. This limitation is checked by comparing
    1.11       * gfn with 0xfffffUL.
    1.12       */
    1.13      if ( paging_mode_hap(d) && (gfn > 0xfffffUL) )
    1.14 +    {
    1.15 +        if ( !test_and_set_bool(d->arch.hvm_domain.amd_npt_4gb_warning) )
    1.16 +            dprintk(XENLOG_WARNING, "Dom%d failed to populate memory beyond"
    1.17 +                    " 4GB: remove 'hap' Xen boot parameter.\n",
    1.18 +                    d->domain_id);
    1.19          return -EINVAL;
    1.20 +    }
    1.21  #endif
    1.22  
    1.23      p2m_lock(d);
     2.1 --- a/xen/include/asm-x86/hvm/domain.h	Wed Jan 16 13:44:18 2008 +0000
     2.2 +++ b/xen/include/asm-x86/hvm/domain.h	Wed Jan 16 15:55:57 2008 +0000
     2.3 @@ -73,6 +73,10 @@ struct hvm_domain {
     2.4  
     2.5      /* Pass-through */
     2.6      struct hvm_iommu       hvm_iommu;
     2.7 +
     2.8 +#if CONFIG_PAGING_LEVELS == 3
     2.9 +    bool_t                 amd_npt_4gb_warning;
    2.10 +#endif
    2.11  };
    2.12  
    2.13  #endif /* __ASM_X86_HVM_DOMAIN_H__ */