aboutsummaryrefslogtreecommitdiff
path: root/block/vpc.c
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2020-05-13 13:05:35 +0200
committerKevin Wolf <kwolf@redhat.com>2020-05-18 19:05:25 +0200
commit8b1869daad17f313bf9a68fd3275448df0ecb7fb (patch)
treed6686fc9a54daf85e6a893fa093ae8d7864bb570 /block/vpc.c
parentff3541c4e27030fe681d0613ef69bdffb0e29f3a (diff)
downloadqemu-8b1869daad17f313bf9a68fd3275448df0ecb7fb.zip
qemu-8b1869daad17f313bf9a68fd3275448df0ecb7fb.tar.gz
qemu-8b1869daad17f313bf9a68fd3275448df0ecb7fb.tar.bz2
block: Make format drivers use child_of_bds
Commonly, they need to pass the BDRV_CHILD_IMAGE set as the BdrvChildRole; but there are exceptions for drivers with external data files (qcow2 and vmdk). Signed-off-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Message-Id: <20200513110544.176672-26-mreitz@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block/vpc.c')
-rw-r--r--block/vpc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/block/vpc.c b/block/vpc.c
index b2a8607..651a673 100644
--- a/block/vpc.c
+++ b/block/vpc.c
@@ -228,8 +228,8 @@ static int vpc_open(BlockDriverState *bs, QDict *options, int flags,
int ret;
int64_t bs_size;
- bs->file = bdrv_open_child(NULL, options, "file", bs, &child_file, 0,
- false, errp);
+ bs->file = bdrv_open_child(NULL, options, "file", bs, &child_of_bds,
+ BDRV_CHILD_IMAGE, false, errp);
if (!bs->file) {
return -EINVAL;
}