|
Pablo Greco |
e6a3ae |
From 9cf495aabeeaf4fdccae83d748a70936e3bf26ab Mon Sep 17 00:00:00 2001
|
|
Pablo Greco |
e6a3ae |
From: Paolo Bonzini <pbonzini@redhat.com>
|
|
Pablo Greco |
e6a3ae |
Date: Mon, 22 Jul 2019 18:22:07 +0100
|
|
Pablo Greco |
e6a3ae |
Subject: [PATCH 26/39] target/i386: kvm: Delete VMX migration blocker on vCPU
|
|
Pablo Greco |
e6a3ae |
init failure
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
RH-Author: Paolo Bonzini <pbonzini@redhat.com>
|
|
Pablo Greco |
e6a3ae |
Message-id: <20190722182220.19374-6-pbonzini@redhat.com>
|
|
Pablo Greco |
e6a3ae |
Patchwork-id: 89624
|
|
Pablo Greco |
e6a3ae |
O-Subject: [RHEL-8.1.0 PATCH qemu-kvm v3 05/18] target/i386: kvm: Delete VMX migration blocker on vCPU init failure
|
|
Pablo Greco |
e6a3ae |
Bugzilla: 1689269
|
|
Pablo Greco |
e6a3ae |
RH-Acked-by: Peter Xu <zhexu@redhat.com>
|
|
Pablo Greco |
e6a3ae |
RH-Acked-by: Laurent Vivier <lvivier@redhat.com>
|
|
Pablo Greco |
e6a3ae |
RH-Acked-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
From: Liran Alon <liran.alon@oracle.com>
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
Commit d98f26073beb ("target/i386: kvm: add VMX migration blocker")
|
|
Pablo Greco |
e6a3ae |
added migration blocker for vCPU exposed with Intel VMX because QEMU
|
|
Pablo Greco |
e6a3ae |
doesn't yet contain code to support migration of nested virtualization
|
|
Pablo Greco |
e6a3ae |
workloads.
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
However, that commit missed adding deletion of the migration blocker in
|
|
Pablo Greco |
e6a3ae |
case init of vCPU failed. Similar to invtsc_mig_blocker. This commit fix
|
|
Pablo Greco |
e6a3ae |
that issue.
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
Fixes: d98f26073beb ("target/i386: kvm: add VMX migration blocker")
|
|
Pablo Greco |
e6a3ae |
Signed-off-by: Liran Alon <liran.alon@oracle.com>
|
|
Pablo Greco |
e6a3ae |
Reviewed-by: Maran Wilson <maran.wilson@oracle.com>
|
|
Pablo Greco |
e6a3ae |
Message-Id: <20190619162140.133674-2-liran.alon@oracle.com>
|
|
Pablo Greco |
e6a3ae |
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
Pablo Greco |
e6a3ae |
(cherry picked from commit 6b2341eeea43c00b8e266026cec84d57af1484dc)
|
|
Pablo Greco |
e6a3ae |
Signed-off-by: Danilo C. L. de Paula <ddepaula@redhat.com>
|
|
Pablo Greco |
e6a3ae |
---
|
|
Pablo Greco |
e6a3ae |
target/i386/kvm.c | 7 +++++--
|
|
Pablo Greco |
e6a3ae |
1 file changed, 5 insertions(+), 2 deletions(-)
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
diff --git a/target/i386/kvm.c b/target/i386/kvm.c
|
|
Pablo Greco |
e6a3ae |
index 875412c..8e861a1 100644
|
|
Pablo Greco |
e6a3ae |
--- a/target/i386/kvm.c
|
|
Pablo Greco |
e6a3ae |
+++ b/target/i386/kvm.c
|
|
Pablo Greco |
e6a3ae |
@@ -798,7 +798,7 @@ int kvm_arch_init_vcpu(CPUState *cs)
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
r = kvm_arch_set_tsc_khz(cs);
|
|
Pablo Greco |
e6a3ae |
if (r < 0) {
|
|
Pablo Greco |
e6a3ae |
- goto fail;
|
|
Pablo Greco |
e6a3ae |
+ return r;
|
|
Pablo Greco |
e6a3ae |
}
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
/* vcpu's TSC frequency is either specified by user, or following
|
|
Pablo Greco |
e6a3ae |
@@ -1142,7 +1142,7 @@ int kvm_arch_init_vcpu(CPUState *cs)
|
|
Pablo Greco |
e6a3ae |
if (local_err) {
|
|
Pablo Greco |
e6a3ae |
error_report_err(local_err);
|
|
Pablo Greco |
e6a3ae |
error_free(invtsc_mig_blocker);
|
|
Pablo Greco |
e6a3ae |
- return r;
|
|
Pablo Greco |
e6a3ae |
+ goto fail2;
|
|
Pablo Greco |
e6a3ae |
}
|
|
Pablo Greco |
e6a3ae |
/* for savevm */
|
|
Pablo Greco |
e6a3ae |
vmstate_x86_cpu.unmigratable = 1;
|
|
Pablo Greco |
e6a3ae |
@@ -1190,6 +1190,9 @@ int kvm_arch_init_vcpu(CPUState *cs)
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
fail:
|
|
Pablo Greco |
e6a3ae |
migrate_del_blocker(invtsc_mig_blocker);
|
|
Pablo Greco |
e6a3ae |
+ fail2:
|
|
Pablo Greco |
e6a3ae |
+ migrate_del_blocker(vmx_mig_blocker);
|
|
Pablo Greco |
e6a3ae |
+
|
|
Pablo Greco |
e6a3ae |
return r;
|
|
Pablo Greco |
e6a3ae |
}
|
|
Pablo Greco |
e6a3ae |
|
|
Pablo Greco |
e6a3ae |
--
|
|
Pablo Greco |
e6a3ae |
1.8.3.1
|
|
Pablo Greco |
e6a3ae |
|