Skip to contentSkip to conversation

ioemu: need probe backing file format

PATCH In review Wei Kong 2 participants 2 messages Aug 18, 2009

lore
Share & tools
lore

Wei Kong

author
#0 lore raw

PATCH 1/1 ioemu: need probe backing file format

Revert changeset 17646

Due to qcow2 also has backing file.

--- xen-3.4.0-testing/tools/ioemu-remote/block.c 2009-08-18
18:35:42.000000000 +0800
+++ xen-3.4.0-testing/tools/ioemu-remote/block.c 2009-08-18
18:35:46.000000000 +0800
@@ -450,7 +450,7 @@ int bdrv_open2(BlockDriverState *bs, con

         bs->backing_hd = bdrv_new("");
         path_combine(backing_filename, sizeof(backing_filename),
                      filename, bs->backing_file);
-        ret = bdrv_open2(bs->backing_hd, backing_filename, open_flags,
&bdrv_raw);
+        ret = bdrv_open(bs->backing_hd, backing_filename, open_flags,
&bdrv_raw);
         if (ret < 0) {
             bdrv_close(bs);
             return ret;

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

#1 lore raw

Wei Kong writes ("[Xen-devel] [PATCH] ioemu: need probe backing file format"):

Quoted 2 lines

Revert changeset 17646
Due to qcow2 also has backing file.

I'm not sure what you mean exactly or what you are trying to achieve, but guessing slightly:

Do you mean that you have a qcow2 image which has a backing file other than in raw format (eg, another cow image) ? If so that is sadly not supported in Xen; the version of qemu we currently have has no way of recording the backing file format and format probing is a security vulnerability, as has been discussed several times.

Quoted 4 lines

- ret = bdrv_open2(bs->backing_hd, backing_filename, open_flags,
&bdrv_raw);
+ ret = bdrv_open(bs->backing_hd, backing_filename, open_flags,
&bdrv_raw);

In any case this is wrong because bdrv_open has one fewer arguments than bdrv_open2 ...

Ian.