[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH v10 6/9] file-posix: support BDRV_REQ_ALLOCATE
From: |
Anton Nefedov |
Subject: |
Re: [Qemu-block] [PATCH v10 6/9] file-posix: support BDRV_REQ_ALLOCATE |
Date: |
Thu, 13 Dec 2018 12:01:55 +0000 |
On 12/12/2018 8:19 PM, Vladimir Sementsov-Ogievskiy wrote:
> 05.12.2018 17:11, Anton Nefedov wrote:
>> On 5/12/2018 4:25 PM, Vladimir Sementsov-Ogievskiy wrote:
>>> 03.12.2018 13:14, Anton Nefedov wrote:
>>>> }
>>>> #endif
>>>>
>>>> - bs->supported_zero_flags = BDRV_REQ_MAY_UNMAP;
>>>> + bs->supported_zero_flags |= BDRV_REQ_MAY_UNMAP;
>>>> ret = 0;
>>>> fail:
>>>> if (filename && (bdrv_flags & BDRV_O_TEMPORARY)) {
>>>> @@ -1520,6 +1522,10 @@ static ssize_t
>>>> handle_aiocb_write_zeroes(RawPosixAIOData *aiocb)
>>>> }
>>>> s->has_fallocate = false;
>>>> }
>>>> +
>>>> + if (!s->has_fallocate) {
>>>> + aiocb->bs->supported_zero_flags &= ~BDRV_REQ_ALLOCATE;
>>>> + }
>>>>> #endif
>
> hm, if CONFIG_FALLOCATE is disabled, flag will remain in supported_zero_flags
>
right..
I think there should be a separate patch to reset s->has_* in
non-CONFIG_FALLOCATE* cases. Then I'll move this hunk just one line down
under the following #endif
Re: [Qemu-block] [PATCH v10 6/9] file-posix: support BDRV_REQ_ALLOCATE, Alberto Garcia, 2018/12/07
[Qemu-block] [PATCH v10 9/9] iotest 134: test cluster-misaligned encrypted write, Anton Nefedov, 2018/12/03
[Qemu-block] [PATCH v10 5/9] block: treat BDRV_REQ_ALLOCATE as serialising, Anton Nefedov, 2018/12/03
[Qemu-block] [PATCH v10 8/9] qcow2: skip writing zero buffers to empty COW areas, Anton Nefedov, 2018/12/03