[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen stable-4.7] VMX: PLATFORM_INFO MSR is r/o
commit 6e36296c6c38fa735cb91650c443fb096ac0a79d Author: Jan Beulich <jbeulich@xxxxxxxx> AuthorDate: Tue Oct 24 16:49:44 2017 +0200 Commit: Jan Beulich <jbeulich@xxxxxxxx> CommitDate: Tue Oct 24 16:49:44 2017 +0200 VMX: PLATFORM_INFO MSR is r/o Therefore all write attempts should produce #GP, just like on real hardware. Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> Reviewed-by: Roger Pau Monné <roger.pau@xxxxxxxxxx> Acked-by: Kevin Tian <kevin.tian@xxxxxxxxx> --- xen/arch/x86/hvm/vmx/vmx.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c index a924020..bd76e50 100644 --- a/xen/arch/x86/hvm/vmx/vmx.c +++ b/xen/arch/x86/hvm/vmx/vmx.c @@ -2703,7 +2703,7 @@ static int vmx_msr_read_intercept(unsigned int msr, uint64_t *msr_content) break; case MSR_INTEL_PLATFORM_INFO: - if ( rdmsr_safe(MSR_INTEL_PLATFORM_INFO, *msr_content) ) + if ( !boot_cpu_has(X86_FEATURE_MSR_PLATFORM_INFO) ) goto gp_fault; *msr_content = 0; break; @@ -2918,6 +2918,7 @@ static int vmx_msr_write_intercept(unsigned int msr, uint64_t msr_content) goto gp_fault; break; case IA32_FEATURE_CONTROL_MSR: + case MSR_INTEL_PLATFORM_INFO: case MSR_IA32_VMX_BASIC ... MSR_IA32_VMX_VMFUNC: /* None of these MSRs are writeable. */ goto gp_fault; @@ -2932,12 +2933,6 @@ static int vmx_msr_write_intercept(unsigned int msr, uint64_t msr_content) goto gp_fault; break; - case MSR_INTEL_PLATFORM_INFO: - if ( msr_content || - rdmsr_safe(MSR_INTEL_PLATFORM_INFO, msr_content) ) - goto gp_fault; - break; - default: if ( passive_domain_do_wrmsr(msr, msr_content) ) return X86EMUL_OKAY; -- generated by git-patchbot for /home/xen/git/xen.git#stable-4.7 _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx https://lists.xenproject.org/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |