Bug 215929

Summary: kernel deadlocks while performing file operations
Product: File System Reporter: bughunter (yanming)
Component: f2fsAssignee: Default virtual assignee for f2fs (filesystem_f2fs)
Status: RESOLVED CODE_FIX    
Severity: normal CC: chao
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 5.17 Subsystem:
Regression: No Bisected commit-id:
Attachments: case.c, contains file operations

Description bughunter 2022-05-01 14:20:57 UTC
Created attachment 300864 [details]
case.c, contains file operations

I'd mounted a F2FS image with several mount options. When I was performing file operations on the mount point, the kernel hangs, and the process cannot be killed.

The file operations are in case.c, and the image is provided at (https://drive.google.com/file/d/1be1SyKJwBWvQKSnhD0Y05ZquEIPT62-W/view?usp=sharing).

This issue can be reproduced by running the following commands:
losetup /dev/loop0 case.img
mount -o "background_gc=sync,active_logs=4,disable_ext_identify,inline_dentry,data_flush,fsync_mode=posix" /dev/loop0 /mnt/test/
gcc -o case case.c
./case
Comment 1 Chao Yu 2022-05-02 01:16:53 UTC
I can't reproduce this bug... Could you please test based on below bugzilla branch? I've applied all recent fixing patches in that branch.

https://git.kernel.org/pub/scm/linux/kernel/git/chao/linux.git/log/?h=bugzilla
Comment 2 bughunter 2022-05-02 11:56:36 UTC
(In reply to Chao Yu from comment #1)
> I can't reproduce this bug... Could you please test based on below bugzilla
> branch? I've applied all recent fixing patches in that branch.
> 
> https://git.kernel.org/pub/scm/linux/kernel/git/chao/linux.git/log/
> ?h=bugzilla

I've just tried the kernel in this branch, and this bug disappears. It may have been fixed in a recent commit.