[PATCH v2 2/2] libxl: add QED disk format support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



If libxl has QED disk format support, then pass the feature
over to the user.
---
 src/libxl/libxl_conf.c | 11 +++++++++++
 src/xenconfig/xen_xl.c |  6 ++++++
 2 files changed, 17 insertions(+)

diff --git a/src/libxl/libxl_conf.c b/src/libxl/libxl_conf.c
index 288712f65..02945ae1a 100644
--- a/src/libxl/libxl_conf.c
+++ b/src/libxl/libxl_conf.c
@@ -745,6 +745,12 @@ libxlMakeDisk(virDomainDiskDefPtr l_disk, libxl_device_disk *x_disk)
                 x_disk->format = LIBXL_DISK_FORMAT_RAW;
                 x_disk->backend = LIBXL_DISK_BACKEND_TAP;
                 break;
+#ifdef LIBXL_HAVE_QED
+            case VIR_STORAGE_FILE_QED:
+                x_disk->format = LIBXL_DISK_FORMAT_QED;
+                x_disk->backend = LIBXL_DISK_BACKEND_QDISK;
+                break;
+#endif
             default:
                 virReportError(VIR_ERR_INTERNAL_ERROR,
                                _("libxenlight does not support disk format %s "
@@ -762,6 +768,11 @@ libxlMakeDisk(virDomainDiskDefPtr l_disk, libxl_device_disk *x_disk)
             case VIR_STORAGE_FILE_QCOW2:
                 x_disk->format = LIBXL_DISK_FORMAT_QCOW2;
                 break;
+#ifdef LIBXL_HAVE_QED
+            case VIR_STORAGE_FILE_QED:
+                x_disk->format = LIBXL_DISK_FORMAT_QED;
+                break;
+#endif
             case VIR_STORAGE_FILE_VHD:
                 x_disk->format = LIBXL_DISK_FORMAT_VHD;
                 break;
diff --git a/src/xenconfig/xen_xl.c b/src/xenconfig/xen_xl.c
index f197267bb..edaa8764d 100644
--- a/src/xenconfig/xen_xl.c
+++ b/src/xenconfig/xen_xl.c
@@ -394,6 +394,12 @@ xenParseXLDisk(virConfPtr conf, virDomainDefPtr def)
                 case LIBXL_DISK_FORMAT_EMPTY:
                     break;
 
+#ifdef LIBXL_HAVE_QED
+                case LIBXL_DISK_FORMAT_QED:
+                    disk->src->format = VIR_STORAGE_FILE_QED;
+                    break;
+#endif
+
                 default:
                     virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
                                    _("disk image format not supported: %s"),
-- 
2.11.0

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]
  Powered by Linux