]> xenbits.xensource.com Git - libvirt.git/commitdiff
qemuMigrationDstPrepareStorage: Properly consider path for 'vdpa' devices
authorPeter Krempa <pkrempa@redhat.com>
Fri, 16 Feb 2024 15:40:20 +0000 (16:40 +0100)
committerPeter Krempa <pkrempa@redhat.com>
Wed, 21 Feb 2024 13:15:48 +0000 (14:15 +0100)
Allow storage migration of VDPA devices by properly checking that they
exist on the destionation. Pre-creation is not supported but if the
device exists the migration should be able to succeed.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/qemu/qemu_migration.c

index 3e0aae4e7c93b2e7fadce5e2bf4f82b7c17e89a9..5e27cd5dbe11cedc26a7399dc56d06ec7cdfab07 100644 (file)
@@ -479,10 +479,13 @@ qemuMigrationDstPrepareStorage(virDomainObj *vm,
             diskSrcPath = nvmePath;
             break;
 
+        case VIR_STORAGE_TYPE_VHOST_VDPA:
+            diskSrcPath = disk->src->vdpadev;
+            break;
+
         case VIR_STORAGE_TYPE_NETWORK:
         case VIR_STORAGE_TYPE_VOLUME:
         case VIR_STORAGE_TYPE_VHOST_USER:
-        case VIR_STORAGE_TYPE_VHOST_VDPA:
         case VIR_STORAGE_TYPE_LAST:
         case VIR_STORAGE_TYPE_NONE:
             break;