qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v4 30/30] iotests: Add tests for qcow2 images with extended L


From: Alberto Garcia
Subject: Re: [PATCH v4 30/30] iotests: Add tests for qcow2 images with extended L2 entries
Date: Mon, 13 Apr 2020 19:16:48 +0200
User-agent: Notmuch/0.18.2 (http://notmuchmail.org) Emacs/24.4.1 (i586-pc-linux-gnu)

On Thu 09 Apr 2020 02:22:37 PM CEST, Max Reitz wrote:
>> +    ### Write subcluster #31-#34 (cluster overlap) ###
>
> #31-#34, I think.

That's what I wrote :-?

>> +    ### Partially zeroize an unallocated cluster (#3)
>> +    if [ "$use_backing_file" = "yes" ]; then
>> +        alloc="`seq 0 15`"; zero=""
>
> Isn’t this a TODO?  (I.e., ideally we’d want the first 16 subclusters
> to be zero, and the last 16 subclusters to be unallocated, right?)
>
> (I’m asking because you did raise a TODO for the “Zero subcluster #1”
> test)

Maybe, but I just implemented zeroize at the subcluster level :-) Wait
for the next version of the series.

>> +    echo
>> +    echo "### Compressed cluster with subcluster bitmap != 0 - 
>> $corruption_test_cmd test ###"
>> +    echo
>> +    # We actually don't consider this a corrupted image.
>> +    # The bitmap in compressed clusters is unused so QEMU should just 
>> ignore it.
>> +    _make_test_img 1M
>> +    $QEMU_IO -c 'write -q -P 11 -c 0 64k' "$TEST_IMG"
>> +    poke_file "$TEST_IMG" $(($l2_offset+11)) "\x01\x01"
>> +    alloc="24"; zero="0"
>> +    _verify_l2_bitmap 0 "$alloc" "$zero"
>> +    $QEMU_IO -c "$corruption_test_cmd -P 11 0 64k" "$TEST_IMG" | 
>> _filter_qemu_io
>
> It might be interesting to see the bitmap after the write, i.e., that
> it’s just been ignored.

Yeah, why not.

>> +echo "# 16K clusters, 64GB, extended_l2=off" # This needs one L1 table
>
> You mean one full L1 table cluster?
>
>> +$QEMU_IMG measure --size 64G -O qcow2 -o cluster_size=16k,extended_l2=off
>> +echo "# 16K clusters, 64GB, extended_l2=on"  # This needs two L2 tables
>
> And two full L1 table clusters?

You're right, I'll correct that.

Berto



reply via email to

[Prev in Thread] Current Thread [Next in Thread]