summaryrefslogtreecommitdiffstats
path: root/block/qcow2-cluster.c
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2015-02-10 15:28:48 -0500
committerKevin Wolf <kwolf@redhat.com>2015-03-10 14:02:21 +0100
commit0e06528e980b8ac7695a219f8405d3cdc52a1381 (patch)
treefa20bdce42cbd7327792f009dff30cf721978694 /block/qcow2-cluster.c
parent2aabe7c7a16cee6b1b54592fa05b5f9c23c89bc0 (diff)
downloadhqemu-0e06528e980b8ac7695a219f8405d3cdc52a1381.zip
hqemu-0e06528e980b8ac7695a219f8405d3cdc52a1381.tar.gz
qcow2: Use 64 bits for refcount values
Refcounts may have a width of up to 64 bits, so qemu should use the same width to represent refcount values internally. Signed-off-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block/qcow2-cluster.c')
-rw-r--r--block/qcow2-cluster.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c
index 405329a..ed2b44d 100644
--- a/block/qcow2-cluster.c
+++ b/block/qcow2-cluster.c
@@ -1640,7 +1640,7 @@ static int expand_zero_clusters_in_l1(BlockDriverState *bs, uint64_t *l1_table,
for (i = 0; i < l1_size; i++) {
uint64_t l2_offset = l1_table[i] & L1E_OFFSET_MASK;
bool l2_dirty = false;
- uint16_t l2_refcount;
+ uint64_t l2_refcount;
if (!l2_offset) {
/* unallocated */
OpenPOWER on IntegriCloud