# HG changeset patch
# User Sharad Mishra <snmishra(a)us.ibm.com>
# Date 1293079091 28800
# Node ID 353104beb7b459f715f64bd88feb899bfce4458f
# Parent 35396e5b805193c024b6d4f065136d7b57a0b03d
Added support for qcow2 format type.
Only 'raw' storage volume was supported by libvirt-cim.
This patch adds support for qcow2.
Signed-off-by: Sharad Mishra <snmishra(a)us.ibm.com>
diff -r 35396e5b8051 -r 353104beb7b4 libxkutil/pool_parsing.h
--- a/libxkutil/pool_parsing.h Tue Dec 14 13:59:51 2010 -0800
+++ b/libxkutil/pool_parsing.h Wed Dec 22 20:38:11 2010 -0800
@@ -66,7 +66,8 @@
struct storage_vol {
enum {VOL_FORMAT_UNKNOWN,
- VOL_FORMAT_RAW} format_type;
+ VOL_FORMAT_RAW,
+ VOL_FORMAT_QCOW2} format_type;
char *vol_name;
char *path;
uint16_t alloc;
diff -r 35396e5b8051 -r 353104beb7b4 libxkutil/xmlgen.c
--- a/libxkutil/xmlgen.c Tue Dec 14 13:59:51 2010 -0800
+++ b/libxkutil/xmlgen.c Wed Dec 22 20:38:11 2010 -0800
@@ -1134,6 +1134,8 @@
switch (type) {
case VOL_FORMAT_RAW:
return "raw";
+ case VOL_FORMAT_QCOW2:
+ return "qcow2";
default:
CU_DEBUG("Unsupported storage volume type");
}