[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH for-4.1] util/hbitmap: update orig_size on trunc
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH for-4.1] util/hbitmap: update orig_size on truncate |
Date: |
Mon, 5 Aug 2019 16:50:28 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 |
On 05/08/19 14:19, Max Reitz wrote:
> On 05.08.19 14:01, Vladimir Sementsov-Ogievskiy wrote:
>> Without this, hbitmap_next_zero and hbitmap_next_dirty_area are broken
>> after truncate. So, orig_size is broken since it's introduction in
>> 76d570dc495c56bb.
>>
>> Fixes: 76d570dc495c56bb
>> Signed-off-by: Vladimir Sementsov-Ogievskiy <address@hidden>
>> ---
>>
>> Hi!
>>
>> Here is one more hbitmap bug I noticed. It's my fault, I'm sorry :(
>> Broken in 4.0, but if we are already going to fix in 4.1 some things
>> around it, it's a small meaningful addition.
>
> Hm. :-/
>
>> Users of broken API are incremental backup, sync mirror (but it may not
>> be broken, if truncates not allowed during mirror, are they?),
>
> It doesn’t appear that way (we don’t share BLK_PERM_RESIZE).
>
>> bitmap export through NBD.
>
> I suppose that counts as block-y enough for me to take it. Well, I’d
> still like a test case to see the impact... I’ll see whether I can come
> up with something.
And also a unit test...
Paolo