mirror of https://gitee.com/openkylin/qemu.git
vmdk: Make block_status recurse for flat extents
Fixes: 69f47505ee
Signed-off-by: Max Reitz <mreitz@redhat.com>
Message-id: 20190725155512.9827-3-mreitz@redhat.com
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: John Snow <jsnow@redhat.com>
Signed-off-by: Max Reitz <mreitz@redhat.com>
This commit is contained in:
parent
ad6434dc62
commit
4dd84ac9a7
|
@ -1692,6 +1692,9 @@ static int coroutine_fn vmdk_co_block_status(BlockDriverState *bs,
|
|||
if (!extent->compressed) {
|
||||
ret |= BDRV_BLOCK_OFFSET_VALID;
|
||||
*map = cluster_offset + index_in_cluster;
|
||||
if (extent->flat) {
|
||||
ret |= BDRV_BLOCK_RECURSE;
|
||||
}
|
||||
}
|
||||
*file = extent->file->bs;
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue