From: Eric Blake <eblake@redhat.com>
To: Alberto Garcia <berto@igalia.com>, qemu-devel@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>,
qemu-block@nongnu.org, Max Reitz <mreitz@redhat.com>
Subject: Re: [Qemu-devel] [PATCH] qcow2: Reset free_cluster_index when allocating a new refcount block
Date: Wed, 21 Mar 2018 08:31:37 -0500 [thread overview]
Message-ID: <635c2d4a-3cb1-06db-70d0-423a28b78216@redhat.com> (raw)
In-Reply-To: <78205471-01fc-9d60-590e-feab0df79439@redhat.com>
On 03/21/2018 08:30 AM, Eric Blake wrote:
> On 03/20/2018 08:55 AM, Alberto Garcia wrote:
>> This can be reproduced easily:
>>
>> qemu-img create -f qcow2 -o cluster_size=512 hd.qcow2 1M
>> qemu-io -c 'write 0 124k' hd.qcow2
>
> This reproduction fails if you use non-default refcount_order...
>
>> +++ b/tests/qemu-iotests/121
>> @@ -93,6 +93,26 @@ $QEMU_IO -c 'write 63M 130K' "$TEST_IMG" |
>> _filter_qemu_io
>> _check_test_img
>> +echo
>> +echo '=== Allocating a new refcount block must not leave holes in the
>> image ==='
>> +echo
>> +
>> +IMGOPTS='cluster_size=512' _make_test_img 1M
>
> ...so here, I think IMGOPTS also has to include refcount_bits=4, so that
> calling iotests './check -o refcount_bits=3' or similar doesn't fail the
> test.
Except that it's spelled refcount_bits=16 vs. refcount_bits=8 (we
convert refcount_bits as a power of 2 to refcount_order as an exponent
value written into the qcow2 header).
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
prev parent reply other threads:[~2018-03-21 13:31 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-20 13:55 [Qemu-devel] [PATCH] qcow2: Reset free_cluster_index when allocating a new refcount block Alberto Garcia
2018-03-20 17:54 ` [Qemu-devel] [PATCH for-2.12] " Eric Blake
2018-03-21 9:28 ` Alberto Garcia
2018-03-21 13:08 ` Eric Blake
2018-03-21 13:15 ` Alberto Garcia
2018-03-21 13:30 ` [Qemu-devel] [PATCH] " Eric Blake
2018-03-21 13:31 ` Eric Blake [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=635c2d4a-3cb1-06db-70d0-423a28b78216@redhat.com \
--to=eblake@redhat.com \
--cc=berto@igalia.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).