Re: [f2fs-dev] [PATCH v2 1/4] libf2fs_zoned: Introduce f2fs_report_zones() helper function

2019-08-28 Thread Shinichiro Kawasaki
On Aug 27, 2019 / 09:34, Chao Yu wrote: > On 2019/8/21 12:47, Shin'ichiro Kawasaki wrote: > > To prepare for write pointer consistency check by fsck, add > > f2fs_report_zones() helper function which calls REPORT ZONE command to > > get write pointer status. The function is added to lib/libf2fs_zon

Re: [f2fs-dev] [PATCH v7] Add flags option to get xattr method paired to __vfs_getxattr

2019-08-28 Thread Amir Goldstein
On Wed, Aug 28, 2019 at 11:15 AM Jan Kara via samba-technical wrote: > > On Tue 20-08-19 11:06:48, Mark Salyzyn wrote: > > diff --git a/Documentation/filesystems/Locking > > b/Documentation/filesystems/Locking > > index 204dd3ea36bb..e2687f21c7d6 100644 > > --- a/Documentation/filesystems/Locking

[PATCH 1/4] f2fs: fix extent corrupotion during directIO in LFS mode

2019-08-28 Thread Chao Yu
In LFS mode, por_fsstress testcase reports a bug as below: [ASSERT] (fsck_chk_inode_blk: 931) --> ino: 0x12fe has wrong ext: [pgofs:142, blk:215424, len:16] Since commit f847c699cff3 ("f2fs: allow out-place-update for direct IO in LFS mode"), we start to allow OPU mode for direct IO, however, w

[PATCH 4/4] f2fs: fix to add missing F2FS_IO_ALIGNED() condition

2019-08-28 Thread Chao Yu
In f2fs_allocate_data_block(), we will reset fio.retry for IO alignment feature instead of IO serialization feature. In addition, spread F2FS_IO_ALIGNED() to check IO alignment feature status explicitly. Signed-off-by: Chao Yu --- fs/f2fs/data.c| 6 +- fs/f2fs/segment.c | 4 +++- 2 file

[PATCH 2/4] f2fs: fix to handle error path correctly in f2fs_map_blocks

2019-08-28 Thread Chao Yu
In f2fs_map_blocks(), we should bail out once __allocate_data_block() failed. Fixes: f847c699cff3 ("f2fs: allow out-place-update for direct IO in LFS mode") Signed-off-by: Chao Yu --- fs/f2fs/data.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fs/f2fs/data.c b/fs/f

[f2fs-dev] [PATCH 3/4] f2fs: fix to fallback to buffered IO in IO aligned mode

2019-08-28 Thread Chao Yu
In LFS mode, we allow OPU for direct IO, however, we didn't consider IO alignment feature, so direct IO can trigger unaligned IO, let's just fallback to buffered IO to keep correct IO alignment semantics in all places. Fixes: f847c699cff3 ("f2fs: allow out-place-update for direct IO in LFS mode")

Re: [f2fs-dev] [PATCH v2 4/4] fsck.f2fs: Check write pointer consistency with valid blocks count

2019-08-28 Thread Shinichiro Kawasaki
On Aug 27, 2019 / 10:25, Chao Yu wrote: > On 2019/8/21 12:48, Shin'ichiro Kawasaki wrote: > > When sudden f2fs shutdown happens on zoned block devices, write > > pointers can be inconsistent with valid blocks counts in meta data. > > The failure scenario is as follows: > > > > - Just before a sudd

Re: [f2fs-dev] [PATCH v8] Add flags option to get xattr method paired to __vfs_getxattr

2019-08-28 Thread Christoph Hellwig
On Tue, Aug 27, 2019 at 08:05:15AM -0700, Mark Salyzyn wrote: > Replace arguments for get and set xattr methods, and __vfs_getxattr > and __vfs_setaxtr functions with a reference to the following now > common argument structure: Yikes. That looks like a mess. Why can't we pass a kernel-only flag

Re: [f2fs-dev] [PATCH v8] Add flags option to get xattr method paired to __vfs_getxattr

2019-08-28 Thread Mark Salyzyn via Linux-f2fs-devel
On 8/28/19 7:24 AM, Christoph Hellwig wrote: On Tue, Aug 27, 2019 at 08:05:15AM -0700, Mark Salyzyn wrote: Replace arguments for get and set xattr methods, and __vfs_getxattr and __vfs_setaxtr functions with a reference to the following now common argument structure: Yikes. That looks like a m

Re: [f2fs-dev] [GIT PULL] vfs: Add support for timestamp limits

2019-08-28 Thread Deepa Dinamani
That will be merged > through > Russell's tree. > > Thanks, > Deepa > > The following changes since commit 5d18cb62218608a1388858880ad3ec76d6cb0d3b: > > Add linux-next specific files for 20190828 (2019-08-28 19:59:14 +1000) > > are available in the Git re

Re: [f2fs-dev] [PATCH v2 3/4] fsck.f2fs: Check write pointer consistency with current segments

2019-08-28 Thread Shinichiro Kawasaki
On Aug 27, 2019 / 10:13, Chao Yu wrote: > On 2019/8/27 10:01, Chao Yu wrote: > > On 2019/8/21 12:48, Shin'ichiro Kawasaki wrote: > >> On sudden f2fs shutdown, zoned block device status and f2fs current > >> segment positions in meta data can be inconsistent. When f2fs shutdown > >> happens before w

[f2fs-dev] [PATCH v3 0/2] fsck: Check write pointers of zoned block devices

2019-08-28 Thread Shin'ichiro Kawasaki
On sudden f2fs shutdown, zoned block device status and f2fs meta data can be inconsistent. When f2fs shutdown happens during write operations, write pointers on the device go forward but the f2fs meta data does not reflect write pointer progress. This inconsistency will eventually causes "Unaligned

[f2fs-dev] [PATCH v3 1/2] libf2fs_zoned: Introduce f2fs_report_zones() helper function

2019-08-28 Thread Shin'ichiro Kawasaki
To prepare for write pointer consistency check by fsck, add f2fs_report_zones() helper function which calls REPORT ZONE command to get write pointer status. The function is added to lib/libf2fs_zoned which gathers zoned block device related functions. To check write pointer consistency with f2fs m

[f2fs-dev] [PATCH v3 2/2] fsck.f2fs: Check write pointer consistency with current segments

2019-08-28 Thread Shin'ichiro Kawasaki
On sudden f2fs shutdown, zoned block device status and f2fs current segment positions in meta data can be inconsistent. When f2fs shutdown happens before write operations completes, write pointers of zoned block devices can go further but f2fs meta data keeps current segments at positions before th