[f2fs-dev] [PATCH Vx 1/1] f2fs: Avoid deadlock between writeback and checkpoint

2021-11-08 Thread niuzhiguo84
From: Zhiguo Niu There could be a scenario as following: The inodeA and inodeB are in b_io queue of writeback inodeA : f2fs's node inode inodeB : a dir inode with only one dirty pages, and the node page of inodeB cached into inodeA writeback: wb_workfn wb_writeback blk_start_plug loop {

[f2fs-dev] [PATCH v2] f2fs: compress: reduce one page array alloc and free when write compressed page

2021-11-08 Thread Fengnan Chang
Don't alloc new page pointers array to replace old, just use old, introduce valid_nr_cpages to indicate valid number of page pointers in array, try to reduce one page array alloc and free when write compress page. Signed-off-by: Fengnan Chang --- fs/f2fs/compress.c | 27 +

Re: [f2fs-dev] Do we need serial io for compress file?

2021-11-08 Thread 常凤楠
> -Original Message- > From: changfeng...@vivo.com On Behalf Of > Chao Yu > Sent: Monday, November 8, 2021 10:30 PM > To: 常凤楠 ; jaeg...@kernel.org > Cc: linux-f2fs-devel@lists.sourceforge.net > Subject: Re: Do we need serial io for compress file? > > On 2021/11/8 16:56, 常凤楠 wrote: > > A

[f2fs-dev] [PATCH] f2fs: provide a way to attach HIPRI for Direct IO

2021-11-08 Thread Jaegeuk Kim
This patch adds a way to attach HIPRI by expanding the existing sysfs's data_io_flag. User can measure IO performance by enabling it. Signed-off-by: Jaegeuk Kim --- Documentation/ABI/testing/sysfs-fs-f2fs | 16 +--- fs/f2fs/data.c | 2 ++ fs/f2fs/f2fs.h

Re: [f2fs-dev] Do we need serial io for compress file?

2021-11-08 Thread 常凤楠
> -Original Message- > From: changfeng...@vivo.com On Behalf Of > Chao Yu > Sent: Monday, November 8, 2021 10:21 PM > To: 常凤楠 ; jaeg...@kernel.org > Cc: linux-f2fs-devel@lists.sourceforge.net > Subject: Re: Do we need serial io for compress file? > > On 2021/11/8 11:54, Fengnan Chang wr

[f2fs-dev] [GIT PULL] zstd changes for v5.16

2021-11-08 Thread Nick Terrell
From: Nick Terrell Hi Linus, I am sending you a pull request to add myself as the maintainer of zstd and update the zstd version in the kernel, which is now 4 years out of date, to the latest zstd release. This includes bug fixes, much more extensive fuzzing, and performance improvements. And g

Re: [f2fs-dev] [PATCH v1] f2fs: compress: reduce one page array alloc and free when write compressed page

2021-11-08 Thread Chao Yu
On 2021/7/23 16:37, Fengnan Chang wrote: Don't alloc new page array to replace old, just use old page array, try to reduce one page array alloc and free when write compress page. Signed-off-by: Fengnan Chang --- fs/f2fs/compress.c | 18 -- fs/f2fs/f2fs.h | 1 + 2 files

Re: [f2fs-dev] Do we need serial io for compress file?

2021-11-08 Thread Chao Yu
On 2021/11/8 16:56, 常凤楠 wrote: Anyway, I did some modify to verify my idea, and did some test, not found problem for now. Could you please consider: 1. pin file 2. fallocate file w/ filesize keeped - it will preallocate physical blocks aligned to segments 3. unpin file 4. overwrite compressed

Re: [f2fs-dev] Do we need serial io for compress file?

2021-11-08 Thread Chao Yu
On 2021/11/8 11:54, Fengnan Chang wrote: In my test, serial io for compress file will make multithread small write performance drop a lot. I'm try to fingure out why we need __should_serialize_io, IMO, we use __should_serialize_io to avoid deadlock or try to improve sequential performance, but

Re: [f2fs-dev] Do we need serial io for compress file?

2021-11-08 Thread 常凤楠
Anyway, I did some modify to verify my idea, and did some test, not found problem for now. The modify as follows: diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c index f4fd6c246c9a..0ed677efe820 100644 --- a/fs/f2fs/data.c +++ b/fs/f2fs/data.c @@ -3165,8 +3165,6 @@ static inline bool __should_seria