[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation
From: |
Kevin Wolf |
Subject: |
Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation |
Date: |
Thu, 28 Jul 2011 14:41:02 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20110707 Thunderbird/5.0 |
Am 28.07.2011 14:15, schrieb Christoph Hellwig:
>> Christoph, on another note: Can we rely on Linux AIO never returning
>> short writes except on EOF? Currently we return -EINVAL in this case, so
"short reads" I meant, of course.
>> I hope it's true or we wouldn't return the correct error code.
>
> More or less. There's one corner case for all Linux I/O, and that is
> only writes up to INT_MAX are supported, and larger writes (and reads)
> get truncated to it. It's pretty nasty, but Linux has been vocally
> opposed to fixing this issue.
I think we can safely ignore this. So just replacing the current
ret = -EINVAL; by a memset(buf + ret, 0, len - ret); ret = 0; should be
okay, right? (Of course using the qiov versions, but you get the idea)
Kevin
- [Qemu-devel] [PATCH 0/2] improve Linux AIO support, Frediano Ziglio, 2011/07/27
- [Qemu-devel] [PATCH 1/2] linux aio: support flush operation, Frediano Ziglio, 2011/07/27
- Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation, Christoph Hellwig, 2011/07/27
- Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation, Frediano Ziglio, 2011/07/27
- Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation, Christoph Hellwig, 2011/07/27
- Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation, Kevin Wolf, 2011/07/28
- Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation, Christoph Hellwig, 2011/07/28
- Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation,
Kevin Wolf <=
- Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation, Christoph Hellwig, 2011/07/29
- Re: [Qemu-devel] [PATCH 1/2] linux aio: support flush operation, Stefan Hajnoczi, 2011/07/29
[Qemu-devel] [PATCH 2/2] aio: use Linux AIO even if nocache is not specified, Frediano Ziglio, 2011/07/27