]> git.proxmox.com Git - qemu.git/commit - block.c
block: add bdrv_open_backing_file
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 18 Oct 2012 14:49:17 +0000 (16:49 +0200)
committerKevin Wolf <kwolf@redhat.com>
Wed, 24 Oct 2012 08:26:19 +0000 (10:26 +0200)
commit9156df12a4f3b3db63d1b292d081d814f02e311a
tree6b541c26aa1e698d2eb9055de28650e4606c05f0
parent9887b616619f62977682e76927a9b5a6134cc8bf
block: add bdrv_open_backing_file

Mirroring runs without the backing file so that it can be copied outside
QEMU.  However, we need to add it at the time the job is completed and
QEMU switches to the target.  Factor out the common bits of opening an
image and completing a mirroring operation.

The new function does not assume that the file is closed immediately after
it returns failure, so it keeps the BDRV_O_NO_BACKING flag up-to-date.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block.c
block.h