aboutsummaryrefslogtreecommitdiff
path: root/block/io.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2017-03-08 15:02:49 +0100
committerKevin Wolf <kwolf@redhat.com>2017-03-13 12:49:33 +0100
commitb64aa441955b9aa72a05456650303015ac2bea28 (patch)
tree5368ff3c58810f03307f9b867f5a0691fa073272 /block/io.c
parent466787fbca9b25b47365b3d2c09d308df67a61db (diff)
downloadqemu-b64aa441955b9aa72a05456650303015ac2bea28.zip
qemu-b64aa441955b9aa72a05456650303015ac2bea28.tar.gz
qemu-b64aa441955b9aa72a05456650303015ac2bea28.tar.bz2
block: Request block status from *file for BDRV_BLOCK_RAW
This fixes bdrv_co_get_block_status() for the bdrv_mirror_top block driver, which must fall through to bs->backing instead of bs->file. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'block/io.c')
-rw-r--r--block/io.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/io.c b/block/io.c
index 8f38d46..2709a70 100644
--- a/block/io.c
+++ b/block/io.c
@@ -1760,7 +1760,7 @@ static int64_t coroutine_fn bdrv_co_get_block_status(BlockDriverState *bs,
if (ret & BDRV_BLOCK_RAW) {
assert(ret & BDRV_BLOCK_OFFSET_VALID);
- ret = bdrv_get_block_status(bs->file->bs, ret >> BDRV_SECTOR_BITS,
+ ret = bdrv_get_block_status(*file, ret >> BDRV_SECTOR_BITS,
*pnum, pnum, file);
goto out;
}