diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2018-11-14 10:38:13 +0100 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2018-11-27 15:06:14 +0100 |
commit | d98f26073bebddcd3da0ba1b86c3a34e840c0fb8 (patch) | |
tree | 6083db8e4979eec8af4efd183bbb068bda553a3d /target | |
parent | 4822f1ee9efa8df56e29db0a68323b484bdb0335 (diff) |
target/i386: kvm: add VMX migration blocker
Nested VMX does not support live migration yet. Add a blocker
until that is worked out.
Nested SVM only does not support it, but unfortunately it is
enabled by default for -cpu host so we cannot really disable it.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'target')
-rw-r--r-- | target/i386/kvm.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/target/i386/kvm.c b/target/i386/kvm.c index 3d6739a2b2..2724800686 100644 --- a/target/i386/kvm.c +++ b/target/i386/kvm.c @@ -855,6 +855,7 @@ static int hyperv_init_vcpu(X86CPU *cpu) } static Error *invtsc_mig_blocker; +static Error *vmx_mig_blocker; #define KVM_MAX_CPUID_ENTRIES 100 @@ -1247,6 +1248,17 @@ int kvm_arch_init_vcpu(CPUState *cs) !!(c->ecx & CPUID_EXT_SMX); } + if ((env->features[FEAT_1_ECX] & CPUID_EXT_VMX) && !vmx_mig_blocker) { + error_setg(&vmx_mig_blocker, + "Nested VMX virtualization does not support live migration yet"); + r = migrate_add_blocker(vmx_mig_blocker, &local_err); + if (local_err) { + error_report_err(local_err); + error_free(vmx_mig_blocker); + return r; + } + } + if (env->mcg_cap & MCG_LMCE_P) { has_msr_mcg_ext_ctl = has_msr_feature_control = true; } |