From d46a0bb24d6061c1eadcf1136fa73dc7c4ac267d Mon Sep 17 00:00:00 2001 From: Kevin Wolf Date: Wed, 1 Jun 2016 16:55:05 +0200 Subject: qcow2: Implement .bdrv_co_pwritev() This changes qcow2 to implement the byte-based .bdrv_co_pwritev interface rather than the sector-based old one. As preallocation uses the same allocation function as normal writes, and the interface of that function needs to be changed, it is converted in the same patch. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake --- block/qcow2.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'block/qcow2.h') diff --git a/block/qcow2.h b/block/qcow2.h index 175b0c1..b36a7bf 100644 --- a/block/qcow2.h +++ b/block/qcow2.h @@ -539,7 +539,8 @@ int qcow2_encrypt_sectors(BDRVQcow2State *s, int64_t sector_num, int qcow2_get_cluster_offset(BlockDriverState *bs, uint64_t offset, unsigned int *bytes, uint64_t *cluster_offset); int qcow2_alloc_cluster_offset(BlockDriverState *bs, uint64_t offset, - int *num, uint64_t *host_offset, QCowL2Meta **m); + unsigned int *bytes, uint64_t *host_offset, + QCowL2Meta **m); uint64_t qcow2_alloc_compressed_cluster_offset(BlockDriverState *bs, uint64_t offset, int compressed_size); -- cgit v1.1