ia64/xen-unstable

changeset 15793:828e1df114d4

hvm: Intercept reads of MSR_IA32_MCG_CAP and return 0.

This indicates no machine check "units", which agrees more closely
with Xen's super-minimal machine check architecture (just enough to
allow Windows to run). This fixes a bug that occurs when migrating a
RHEL4-64bit guest to a host with fewer machine check units than the
original host. These host physical details shouldn't be leaking
through to guests.

Signed-off-by: David Lively <dlively@virtualiron.com>
author kfraser@localhost.localdomain
date Wed Aug 29 14:57:12 2007 +0100 (2007-08-29)
parents 747b71c8c4a8
children adad9f3820f1
files xen/arch/x86/hvm/svm/svm.c xen/arch/x86/hvm/vmx/vmx.c
line diff
     1.1 --- a/xen/arch/x86/hvm/svm/svm.c	Wed Aug 29 14:54:14 2007 +0100
     1.2 +++ b/xen/arch/x86/hvm/svm/svm.c	Wed Aug 29 14:57:12 2007 +0100
     1.3 @@ -1876,6 +1876,7 @@ static void svm_do_msr_access(
     1.4              svm_inject_exception(v, TRAP_gp_fault, 1, 0);
     1.5              break;
     1.6  
     1.7 +        case MSR_IA32_MCG_CAP:
     1.8          case MSR_IA32_MCG_STATUS:
     1.9          case MSR_IA32_MC0_STATUS:
    1.10          case MSR_K8_MC1_STATUS:
     2.1 --- a/xen/arch/x86/hvm/vmx/vmx.c	Wed Aug 29 14:54:14 2007 +0100
     2.2 +++ b/xen/arch/x86/hvm/vmx/vmx.c	Wed Aug 29 14:57:12 2007 +0100
     2.3 @@ -2314,6 +2314,7 @@ static int vmx_do_msr_read(struct cpu_us
     2.4          break;
     2.5      case MSR_IA32_VMX_BASIC...MSR_IA32_VMX_PROCBASED_CTLS2:
     2.6          goto gp_fault;
     2.7 +    case MSR_IA32_MCG_CAP:
     2.8      case MSR_IA32_MCG_STATUS:
     2.9      case MSR_IA32_MC0_STATUS:
    2.10      case MSR_K8_MC1_STATUS: