Re: [f2fs-dev] 回覆: f2fs F2FS_IOC_SHUTDOWN hang issue

2024-03-20 Thread Jaegeuk Kim
On 03/20, Light Hsieh (謝明燈) wrote: > On 2024/3/20 8:14, Jaegeuk Kim wrote: > > f2fs_ioc_shutdown(F2FS_GOING_DOWN_NOSYNC)  issue_discard_thread > >   - mnt_want_write_file() > >     - sb_start_write(SB_FREEZE_WRITE) > >                                               - > >

Re: [f2fs-dev] f2fs F2FS_IOC_SHUTDOWN hang issue

2024-03-20 Thread Jaegeuk Kim
Can you try this? https://patchwork.kernel.org/project/f2fs/patch/20240320001442.497813-1-jaeg...@kernel.org/ On 03/20, Light Hsieh (謝明燈) wrote: > Hi Jaegeuk: > > We encounter a deadlock issue when Android is going to poweroff. > Please help check. > > When unmounting of f2fs partition fail

Re: [f2fs-dev] [PATCH v3] f2fs: prevent writing without fallocate() for pinned files

2024-03-20 Thread Daeho Jeong
On Wed, Mar 20, 2024 at 2:38 AM Chao Yu wrote: > > On 2024/3/20 5:23, Daeho Jeong wrote: > > From: Daeho Jeong > > > > In a case writing without fallocate(), we can't guarantee it's allocated > > in the conventional area for zoned stroage. > > > > Signed-off-by: Daeho Jeong > > --- > > v2:

Re: [f2fs-dev] [PATCH] f2fs: avoid the deadlock case when stopping discard thread

2024-03-20 Thread Chao Yu
On 2024/3/20 8:14, Jaegeuk Kim wrote: f2fs_ioc_shutdown(F2FS_GOING_DOWN_NOSYNC) issue_discard_thread - mnt_want_write_file() - sb_start_write(SB_FREEZE_WRITE) - sb_start_intwrite(SB_FREEZE_FS); - f2fs_stop_checkpoint(sbi, false,:

Re: [f2fs-dev] [PATCH v3] f2fs: prevent writing without fallocate() for pinned files

2024-03-20 Thread Chao Yu
On 2024/3/20 5:23, Daeho Jeong wrote: From: Daeho Jeong In a case writing without fallocate(), we can't guarantee it's allocated in the conventional area for zoned stroage. Signed-off-by: Daeho Jeong --- v2: covered the direct io case v3: covered the mkwrite case --- fs/f2fs/data.c | 14

Re: [f2fs-dev] [PATCH V3] f2fs: add REQ_TIME time update for some user behaviors

2024-03-20 Thread Chao Yu
On 2024/3/20 14:22, Zhiguo Niu wrote: some user behaviors requested filesystem operations, which will cause filesystem not idle. Meanwhile adjust some f2fs_update_time(REQ_TIME) positions. Signed-off-by: Zhiguo Niu Reviewed-by: Chao Yu Thanks,

[f2fs-dev] [PATCH v14 7/9] f2fs: Log error when lookup of encoded dentry fails

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
If the volume is in strict mode, generi c_ci_compare can report a broken encoding name. This will not trigger on a bad lookup, which is caught earlier, only if the actual disk name is bad. Suggested-by: Gabriel Krisman Bertazi Signed-off-by: Eugen Hristev --- fs/f2fs/dir.c | 21

[f2fs-dev] [PATCH v14 9/9] f2fs: Move CONFIG_UNICODE defguards into the code flow

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
From: Gabriel Krisman Bertazi Instead of a bunch of ifdefs, make the unicode built checks part of the code flow where possible, as requested by Torvalds. Signed-off-by: Gabriel Krisman Bertazi [eugen.hris...@collabora.com: port to 6.8-rc3] Signed-off-by: Eugen Hristev --- fs/f2fs/namei.c |

[f2fs-dev] [PATCH v14 8/9] ext4: Move CONFIG_UNICODE defguards into the code flow

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
From: Gabriel Krisman Bertazi Instead of a bunch of ifdefs, make the unicode built checks part of the code flow where possible, as requested by Torvalds. Signed-off-by: Gabriel Krisman Bertazi [eugen.hris...@collabora.com: port to 6.8-rc3] Signed-off-by: Eugen Hristev --- fs/ext4/crypto.c |

[f2fs-dev] [PATCH v14 3/9] libfs: Introduce case-insensitive string comparison helper

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
From: Gabriel Krisman Bertazi generic_ci_match can be used by case-insensitive filesystems to compare strings under lookup with dirents in a case-insensitive way. This function is currently reimplemented by each filesystem supporting casefolding, so this reduces code duplication in

[f2fs-dev] [PATCH v14 5/9] f2fs: Reuse generic_ci_match for ci comparisons

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
From: Gabriel Krisman Bertazi Now that ci_match is part of libfs, make f2fs reuse it instead of having a different implementation. Signed-off-by: Gabriel Krisman Bertazi Signed-off-by: Eugen Hristev --- fs/f2fs/dir.c | 58 --- 1 file changed, 4

[f2fs-dev] [PATCH v14 0/9] Cache insensitive cleanup for ext4/f2fs

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
Hello, I am trying to respin the series here : https://www.spinics.net/lists/linux-ext4/msg85081.html I resent some of the v9 patches and got some reviews from Gabriel, I did changes as requested and here is v14. Changes in v14: - fix wrong kfree unchecked call - changed the return code in 3/8

[f2fs-dev] [PATCH v14 4/9] ext4: Reuse generic_ci_match for ci comparisons

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
From: Gabriel Krisman Bertazi Instead of reimplementing ext4_match_ci, use the new libfs helper. It also adds a comment explaining why fname->cf_name.name must be checked prior to the encryption hash optimization, because that tripped me before. Signed-off-by: Gabriel Krisman Bertazi

[f2fs-dev] [PATCH v14 6/9] ext4: Log error when lookup of encoded dentry fails

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
From: Gabriel Krisman Bertazi If the volume is in strict mode, ext4_ci_compare can report a broken encoding name. This will not trigger on a bad lookup, which is caught earlier, only if the actual disk name is bad. Signed-off-by: Gabriel Krisman Bertazi Signed-off-by: Eugen Hristev ---

[f2fs-dev] [PATCH v14 2/9] f2fs: Simplify the handling of cached insensitive names

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
From: Gabriel Krisman Bertazi Keeping it as qstr avoids the unnecessary conversion in f2fs_match Signed-off-by: Gabriel Krisman Bertazi [eugen.hris...@collabora.com: port to 6.8-rc3 and minor changes] Signed-off-by: Eugen Hristev --- fs/f2fs/dir.c | 53

[f2fs-dev] [PATCH v14 1/9] ext4: Simplify the handling of cached insensitive names

2024-03-20 Thread Eugen Hristev via Linux-f2fs-devel
From: Gabriel Krisman Bertazi Keeping it as qstr avoids the unnecessary conversion in ext4_match Signed-off-by: Gabriel Krisman Bertazi [eugen.hris...@collabora.com: port to 6.8-rc3] Signed-off-by: Eugen Hristev --- fs/ext4/ext4.h | 2 +- fs/ext4/namei.c | 23 +++ 2

[f2fs-dev] [PATCH V3] f2fs: add REQ_TIME time update for some user behaviors

2024-03-20 Thread Zhiguo Niu
some user behaviors requested filesystem operations, which will cause filesystem not idle. Meanwhile adjust some f2fs_update_time(REQ_TIME) positions. Signed-off-by: Zhiguo Niu --- v3: modify some update conditions according to Chao's suggeestions v2: update patch according to Chao's suggestions