]> xenbits.xensource.com Git - libvirt.git/commitdiff
qed: Minor updates to QED support patches
authorAdam Litke <agl@us.ibm.com>
Mon, 22 Nov 2010 20:08:17 +0000 (14:08 -0600)
committerEric Blake <eblake@redhat.com>
Mon, 22 Nov 2010 20:21:35 +0000 (13:21 -0700)
This patch makes two corrections to the newly-added QED support patch series:

 - Correct the QED header field offsets
 - Remove XML parsing for VIR_STORAGE_FILE_AUTO_SAFE

Signed-off-by: Adam Litke <agl@us.ibm.com>
src/util/storage_file.c
src/util/storage_file.h

index aa117e768ba81f09c3ce69f262e8ffe19624691d..2612eb650688a41da1a3dad2d9bee32becaef031 100644 (file)
@@ -42,7 +42,7 @@
 
 VIR_ENUM_IMPL(virStorageFileFormat,
               VIR_STORAGE_FILE_LAST,
-              "raw", "probe", "dir", "bochs",
+              "raw", "dir", "bochs",
               "cloop", "cow", "dmg", "iso",
               "qcow", "qcow2", "qed", "vmdk", "vpc")
 
@@ -108,8 +108,8 @@ qedGetBackingStore(char **, int *, const unsigned char *, size_t);
 #define QCOW2_HDR_EXTENSION_BACKING_FORMAT 0xE2792ACA
 
 #define QED_HDR_FEATURES_OFFSET (4+4+4+4)
-#define QED_HDR_IMAGE_SIZE (QED_HDR_FEATURES_OFFSET+8+8+8)
-#define QED_HDR_BACKING_FILE_OFFSET (QED_HDR_IMAGE_SIZE+8+8)
+#define QED_HDR_IMAGE_SIZE (QED_HDR_FEATURES_OFFSET+8+8+8+8)
+#define QED_HDR_BACKING_FILE_OFFSET (QED_HDR_IMAGE_SIZE+8)
 #define QED_HDR_BACKING_FILE_SIZE (QED_HDR_BACKING_FILE_OFFSET+4)
 #define QED_F_BACKING_FILE 0x01
 #define QED_F_BACKING_FORMAT_NO_PROBE 0x04
index 1b918301fb1539aac930b5bb5dae11994f2099f7..04c1bb231a39935cf127d591b8fe8e9a152695fc 100644 (file)
@@ -28,9 +28,9 @@
 # include <stdbool.h>
 
 enum virStorageFileFormat {
+    VIR_STORAGE_FILE_AUTO_SAFE = -2,
     VIR_STORAGE_FILE_AUTO = -1,
     VIR_STORAGE_FILE_RAW = 0,
-    VIR_STORAGE_FILE_AUTO_SAFE,
     VIR_STORAGE_FILE_DIR,
     VIR_STORAGE_FILE_BOCHS,
     VIR_STORAGE_FILE_CLOOP,