Re: [Qemu-devel] [PATCH 3/3] parallels: drop check that bdrv_truncate() is working

2017-08-04 Thread Denis V. Lunev
On 08/04/2017 10:32 PM, Eric Blake wrote: > On 08/04/2017 10:10 AM, Denis V. Lunev wrote: >> This would be actually strange and error prone. If truncate() nowadays >> will fail, there is something fatally wrong. Let's check for that during >> the actual work. >> >> The only fallback case is when

Re: [Qemu-devel] [PATCH 3/3] parallels: drop check that bdrv_truncate() is working

2017-08-04 Thread Eric Blake
On 08/04/2017 10:10 AM, Denis V. Lunev wrote: > This would be actually strange and error prone. If truncate() nowadays > will fail, there is something fatally wrong. Let's check for that during > the actual work. > > The only fallback case is when the file is not zero initialized. In this > case

[Qemu-devel] [PATCH 3/3] parallels: drop check that bdrv_truncate() is working

2017-08-04 Thread Denis V. Lunev
This would be actually strange and error prone. If truncate() nowadays will fail, there is something fatally wrong. Let's check for that during the actual work. The only fallback case is when the file is not zero initialized. In this case we should switch to preallocation via fallocate().