[libvirt PATCH] qemu: Skip pre-creation of NVME disk

Han Han hhan at redhat.com
Thu May 7 06:37:11 UTC 2020


Unlike the file based disk, NVME disk cannot be pre-created by libvirt.
So skip the step of pre-creation.

https://bugzilla.redhat.com/show_bug.cgi?id=1823639

Signed-off-by: Han Han <hhan at redhat.com>
---
 src/qemu/qemu_migration.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c
index 02e8271e..e4bd9077 100644
--- a/src/qemu/qemu_migration.c
+++ b/src/qemu/qemu_migration.c
@@ -221,13 +221,13 @@ qemuMigrationDstPrecreateDisk(virConnectPtr conn,
         break;
 
     case VIR_STORAGE_TYPE_NETWORK:
-        VIR_DEBUG("Skipping creation of network disk '%s'",
+    case VIR_STORAGE_TYPE_NVME:
+        VIR_DEBUG("Skipping creation of disk '%s'",
                   disk->dst);
         return 0;
 
     case VIR_STORAGE_TYPE_BLOCK:
     case VIR_STORAGE_TYPE_DIR:
-    case VIR_STORAGE_TYPE_NVME:
     case VIR_STORAGE_TYPE_NONE:
     case VIR_STORAGE_TYPE_LAST:
         virReportError(VIR_ERR_INTERNAL_ERROR,
-- 
2.25.0




More information about the libvir-list mailing list