Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-10-05 Thread Dave Chinner
On Fri, Oct 02, 2015 at 04:35:53PM +0800, Qu Wenruo wrote: > Hi Dave, I updated the patch and moved it to btrfs. > > But I still has some question about the fallocate behavior. > > Just as the new btrfs test case, I changed the fallocate range, not > to cover the last part, to make the problem

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-10-02 Thread Qu Wenruo
Hi Dave, I updated the patch and moved it to btrfs. But I still has some question about the fallocate behavior. Just as the new btrfs test case, I changed the fallocate range, not to cover the last part, to make the problem more obvious: Btrfs will truncate beyond EOF even that's *not

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-30 Thread Duncan
Qu Wenruo posted on Tue, 29 Sep 2015 18:48:37 +0800 as excerpted: > Both gives quite good expression, I'll pick one of them. ... And for the one-line title, /bull/bad/ should do it. =:^) People wanting details about bad /how/ can look at the fuller description or source. -- Duncan - List

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Qu Wenruo
在 2015年09月29日 18:00, Hugo Mills 写道: On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: Normally, a bull fallocate call on a fully written and synced file should not add an extent. What's a "bull" fallocate call? Is it a typo, or simply something I'm not familiar with? Hugo.

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Filipe Manana
On Tue, Sep 29, 2015 at 11:13 AM, Qu Wenruo wrote: > > > 在 2015年09月29日 18:00, Hugo Mills 写道: >> >> On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: >>> >>> Normally, a bull fallocate call on a fully written and synced file >>> should not add an extent. >> >> >>

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Hugo Mills
On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: > Normally, a bull fallocate call on a fully written and synced file > should not add an extent. What's a "bull" fallocate call? Is it a typo, or simply something I'm not familiar with? Hugo. > But not all filesystem follows the

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Qu Wenruo
在 2015年09月29日 18:33, Eryu Guan 写道: On Tue, Sep 29, 2015 at 06:16:11PM +0800, Qu Wenruo wrote: + +if [ "x$orig_extent_nr" != "x$new_extent_nr" ]; then + echo "number of extents mis-match after bull fallocate" print out the $orig_extent_nr and $new_extent_nr in this failure case? I

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Qu Wenruo
在 2015年09月29日 18:24, Filipe Manana 写道: On Tue, Sep 29, 2015 at 11:13 AM, Qu Wenruo wrote: 在 2015年09月29日 18:00, Hugo Mills 写道: On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: Normally, a bull fallocate call on a fully written and synced file should not

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Eryu Guan
On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: > Normally, a bull fallocate call on a fully written and synced file > should not add an extent. > > But not all filesystem follows the correct behavior. > > Btrfs has a bug to always truncate the last page if the fallocate start >

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Hugo Mills
On Tue, Sep 29, 2015 at 06:13:37PM +0800, Qu Wenruo wrote: > > > 在 2015年09月29日 18:00, Hugo Mills 写道: > >On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: > >>Normally, a bull fallocate call on a fully written and synced file > >>should not add an extent. > > > >What's a "bull"

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Eryu Guan
On Tue, Sep 29, 2015 at 06:16:11PM +0800, Qu Wenruo wrote: > > >>+ > >>+if [ "x$orig_extent_nr" != "x$new_extent_nr" ]; then > >>+ echo "number of extents mis-match after bull fallocate" > > > >print out the $orig_extent_nr and $new_extent_nr in this failure case? I > >think it's useful to see

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Qu Wenruo
在 2015年09月29日 17:55, Eryu Guan 写道: On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: Normally, a bull fallocate call on a fully written and synced file should not add an extent. But not all filesystem follows the correct behavior. Btrfs has a bug to always truncate the last page if

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Dave Chinner
On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: > Normally, a bull fallocate call on a fully written and synced file > should not add an extent. Why not? Filesystems can do whatever they want with extents during a fallocate call. e.g. if the blocks are shared, then fallocate might

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Qu Wenruo
Dave Chinner wrote on 2015/09/30 14:20 +1000: On Wed, Sep 30, 2015 at 09:05:15AM +0800, Qu Wenruo wrote: Dave Chinner wrote on 2015/09/30 07:51 +1000: On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: Normally, a bull fallocate call on a fully written and synced file should not

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Dave Chinner
On Wed, Sep 30, 2015 at 09:05:15AM +0800, Qu Wenruo wrote: > > > Dave Chinner wrote on 2015/09/30 07:51 +1000: > >On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: > >>Normally, a bull fallocate call on a fully written and synced file > >>should not add an extent. > > > >Why not?

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Qu Wenruo
Tsutomu Itoh wrote on 2015/09/30 10:45 +0900: On 2015/09/30 10:05, Qu Wenruo wrote: Dave Chinner wrote on 2015/09/30 07:51 +1000: On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: Normally, a bull fallocate call on a fully written and synced file should not add an extent. Why

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Tsutomu Itoh
On 2015/09/30 10:05, Qu Wenruo wrote: Dave Chinner wrote on 2015/09/30 07:51 +1000: On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: Normally, a bull fallocate call on a fully written and synced file should not add an extent. Why not? Filesystems can do whatever they want with

Re: [PATCH v2] fstests: generic: Check if a bull fallocate will change extent number

2015-09-29 Thread Qu Wenruo
Dave Chinner wrote on 2015/09/30 07:51 +1000: On Tue, Sep 29, 2015 at 05:34:24PM +0800, Qu Wenruo wrote: Normally, a bull fallocate call on a fully written and synced file should not add an extent. Why not? Filesystems can do whatever they want with extents during a fallocate call. e.g. if