[libvirt PATCH] qemu_migration: Delete vDPA check

Eugenio Pérez eperezma at redhat.com
Fri Jul 15 09:14:58 UTC 2022


Currently, the migration code denies migration as long as the VM has a
vhost-vDPA device.

While it's true that vhost-vDPA devices cannot be migrated at the moment, there are plans to be able to migrate them soon.

Libvirt must treat it equal to vhost-kernel devices: Not all of them can
be migrated (the ones that do not expose the feature VHOST_F_LOG_ALL
cannot be migrated). So checks like this one should work for all vhost
devices equally.

A more accurate solution is to ask qemu if it has an active migration
blocker at that moment. Hoever, that require synchronization to avoid
qemu to add one between the query and the actual migration command.

Signed-off-by: Eugenio Pérez <eperezma at redhat.com>
---
 src/qemu/qemu_migration.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c
index 9c3fd41761..4ddf027c83 100644
--- a/src/qemu/qemu_migration.c
+++ b/src/qemu/qemu_migration.c
@@ -1546,12 +1546,6 @@ qemuMigrationSrcIsAllowed(virQEMUDriver *driver,
             virDomainNetDef *net = vm->def->nets[i];
             qemuSlirp *slirp;
 
-            if (net->type == VIR_DOMAIN_NET_TYPE_VDPA) {
-                virReportError(VIR_ERR_OPERATION_INVALID, "%s",
-                               _("vDPA devices cannot be migrated"));
-                return false;
-            }
-
             slirp = QEMU_DOMAIN_NETWORK_PRIVATE(net)->slirp;
 
             if (slirp && !qemuSlirpHasFeature(slirp, QEMU_SLIRP_FEATURE_MIGRATE)) {
-- 
2.31.1



More information about the libvir-list mailing list