Bug 54461

Summary: nVMX: Downgrading nested VMX features from user-space
Product: Virtualization Reporter: Nadav Har'El (nyh)
Component: kvmAssignee: virtualization_kvm
Status: NEW ---    
Severity: enhancement    
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: Subsystem:
Regression: No Bisected commit-id:
Bug Depends on:    
Bug Blocks: 94971, 53601    

Description Nadav Har'El 2013-02-25 13:50:20 UTC
In nested SVM, the sub-features of SVM are all part of CPUID, so we already have a user-space interface (KVM_GET_SUPPORTED_CPUID/KVM_SET_CPUID2) to set a guest's features - which is, for example, useful for dictating a fixed set of features across different hosts.

However, in nested VMX, the VMX sub-features offered or not to the guest are not in CPUID, but rather in MSRs, and currently the nested_vmx_setup_ctls_msrs() function determines their value - without any option for user space to control this. We need some sort of new KVM_SET_READONLY_MSRS ioctl for overriding  (downgrading) nested_vmx_setup_ctls_msrs()'s decisions for a particular guest.