[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v6 1/5] block/io: fix bdrv_co_block_status_above
From: |
Alberto Garcia |
Subject: |
Re: [PATCH v6 1/5] block/io: fix bdrv_co_block_status_above |
Date: |
Thu, 24 Sep 2020 18:20:33 +0200 |
User-agent: |
Notmuch/0.18.2 (http://notmuchmail.org) Emacs/24.4.1 (i586-pc-linux-gnu) |
On Wed 16 Sep 2020 02:20:04 PM CEST, Vladimir Sementsov-Ogievskiy
<vsementsov@virtuozzo.com> wrote:
> bdrv_co_block_status_above has several design problems with handling
> short backing files:
>
> 1. With want_zeros=true, it may return ret with BDRV_BLOCK_ZERO but
> without BDRV_BLOCK_ALLOCATED flag, when actually short backing file
> which produces these after-EOF zeros is inside requested backing
> sequence.
>
> 2. With want_zero=false, it may return pnum=0 prior to actual EOF,
> because of EOF of short backing file.
>
> Fix these things, making logic about short backing files clearer.
>
> With fixed bdrv_block_status_above we also have to improve is_zero in
> qcow2 code, otherwise iotest 154 will fail, because with this patch we
> stop to merge zeros of different types (produced by fully unallocated
> in the whole backing chain regions vs produced by short backing files).
>
> Note also, that this patch leaves for another day the general problem
> around block-status: misuse of BDRV_BLOCK_ALLOCATED as is-fs-allocated
> vs go-to-backing.
>
> Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Alberto Garcia <berto@igalia.com>
Berto
- [PATCH v6 0/5] fix & merge block_status_above and is_allocated_above, Vladimir Sementsov-Ogievskiy, 2020/09/16
- [PATCH v6 4/5] block/io: fix bdrv_is_allocated_above, Vladimir Sementsov-Ogievskiy, 2020/09/16
- [PATCH v6 1/5] block/io: fix bdrv_co_block_status_above, Vladimir Sementsov-Ogievskiy, 2020/09/16
- Re: [PATCH v6 1/5] block/io: fix bdrv_co_block_status_above,
Alberto Garcia <=
- [PATCH v6 5/5] iotests: add commit top->base cases to 274, Vladimir Sementsov-Ogievskiy, 2020/09/16
- [PATCH v6 2/5] block/io: bdrv_common_block_status_above: support include_base, Vladimir Sementsov-Ogievskiy, 2020/09/16
- Re: [PATCH v6 2/5] block/io: bdrv_common_block_status_above: support include_base, Alberto Garcia, 2020/09/23
- [PATCH v6 3/5] block/io: bdrv_common_block_status_above: support bs == base, Vladimir Sementsov-Ogievskiy, 2020/09/16