summaryrefslogtreecommitdiffstats
path: root/hw/block
diff options
context:
space:
mode:
authorMax Reitz2014-02-18 18:33:06 +0100
committerKevin Wolf2014-02-21 21:02:22 +0100
commitddf5636dc9e4be894f2ab4a5f803d915478b5099 (patch)
tree4d5249e6d060518a471a244c02b90cac46ea4d85 /hw/block
parentblock: Change BDS parameter of bdrv_open() to ** (diff)
downloadqemu-ddf5636dc9e4be894f2ab4a5f803d915478b5099.tar.gz
qemu-ddf5636dc9e4be894f2ab4a5f803d915478b5099.tar.xz
qemu-ddf5636dc9e4be894f2ab4a5f803d915478b5099.zip
block: Add reference parameter to bdrv_open()
Allow bdrv_open() to handle references to existing block devices just as bdrv_file_open() is already capable of. Signed-off-by: Max Reitz <mreitz@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'hw/block')
-rw-r--r--hw/block/xen_disk.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/block/xen_disk.c b/hw/block/xen_disk.c
index 14e6d0b56e..61e6ff3208 100644
--- a/hw/block/xen_disk.c
+++ b/hw/block/xen_disk.c
@@ -813,8 +813,8 @@ static int blk_connect(struct XenDevice *xendev)
Error *local_err = NULL;
BlockDriver *drv = bdrv_find_whitelisted_format(blkdev->fileproto,
readonly);
- if (bdrv_open(&blkdev->bs,
- blkdev->filename, NULL, qflags, drv, &local_err) != 0)
+ if (bdrv_open(&blkdev->bs, blkdev->filename, NULL, NULL, qflags,
+ drv, &local_err) != 0)
{
xen_be_printf(&blkdev->xendev, 0, "error: %s\n",
error_get_pretty(local_err));