From 060bee8943c27d4d53f65570fafaa2559fcd87c3 Mon Sep 17 00:00:00 2001 From: Kevin Wolf Date: Fri, 7 Dec 2012 18:08:45 +0100 Subject: qcow2: Drop l2meta.cluster_offset There's no real reason to have an l2meta for normal requests that don't allocate anything. Before we can get rid of it, we must return the host cluster offset in a different way. Signed-off-by: Kevin Wolf --- block/qcow2.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'block/qcow2.h') diff --git a/block/qcow2.h b/block/qcow2.h index 1106b33..24f10012 100644 --- a/block/qcow2.h +++ b/block/qcow2.h @@ -213,9 +213,6 @@ typedef struct QCowL2Meta /** Guest offset of the first newly allocated cluster */ uint64_t offset; - /** Host offset of the first cluster of the request */ - uint64_t cluster_offset; - /** Host offset of the first newly allocated cluster */ uint64_t alloc_offset; @@ -336,7 +333,7 @@ void qcow2_encrypt_sectors(BDRVQcowState *s, int64_t sector_num, int qcow2_get_cluster_offset(BlockDriverState *bs, uint64_t offset, int *num, uint64_t *cluster_offset); int qcow2_alloc_cluster_offset(BlockDriverState *bs, uint64_t offset, - int n_start, int n_end, int *num, QCowL2Meta *m); + int n_start, int n_end, int *num, uint64_t *host_offset, QCowL2Meta *m); uint64_t qcow2_alloc_compressed_cluster_offset(BlockDriverState *bs, uint64_t offset, int compressed_size); -- cgit v1.1