[f2fs-dev] [PATCH] ovl: fix BUG: Dentry still in use in unmount

2023-12-17 Thread Edward Adam Davis via Linux-f2fs-devel
workdir and destdir could be the same when copying up to indexdir. Fixes: c63e56a4a652 ("ovl: do not open/llseek lower file with upper sb_writers held") Reported-and-tested-by: syzbot+8608bb4553edb8c78...@syzkaller.appspotmail.com Signed-off-by: Edward Adam Davis --- fs/overlayfs/copy_up.c | 20

[f2fs-dev] [PATCH] f2fs: fix uaf in destroy_device_list

2024-01-13 Thread Edward Adam Davis via Linux-f2fs-devel
When the call to f2fs_fill_super() fails, only the memory occupied by sbi is released, but s_fs_info is not set to NULL, this will cause the current issue to occur. Reported-and-tested-by: syzbot+a5e651ca75fa0260a...@syzkaller.appspotmail.com Signed-off-by: Edward Adam Davis --- fs/f2fs/super.

[f2fs-dev] [PATCH] f2fs: Add mutex to prevent gc task from being accessed before initialization

2024-07-26 Thread Edward Adam Davis via Linux-f2fs-devel
syzbot report null-ptr-deref Write in f2fs_stop_gc_thread, because shutdown and remount can cause multi-path entry into f2fs_stop_gc_thread, resulting in incorrect access to f2fs_gc_task before it is properly initialized. Reported-and-tested-by: syzbot+1a8e2b31f2ac9bd3d...@syzkaller.appspotmail.c

Re: [f2fs-dev] [syzbot] [f2fs?] WARNING: lock held when returning to user space in f2fs_commit_atomic_write

2024-08-13 Thread Edward Adam Davis via Linux-f2fs-devel
unlock i_gc_rwsem[WRITE] before quiting f2fs_commit_atomic_write Fixes: 7566a155c666 ("f2fs: atomic: fix to not allow GC to pollute atomic_file") Reported-by: syzbot+78ff2855f26377625...@syzkaller.appspotmail.com #syz test: net-next 9e6869691724 diff --git a/fs/f2fs/segment.c b/fs/f2fs/segment.c

Re: [f2fs-dev] [syzbot] [f2fs?] WARNING: lock held when returning to user space in f2fs_commit_atomic_write

2024-08-13 Thread Edward Adam Davis via Linux-f2fs-devel
On Wed, 14 Aug 2024 11:33:32 +0800, Chao Yu wrote: > > unlock i_gc_rwsem[WRITE] before quiting f2fs_commit_atomic_write > > > > Fixes: 7566a155c666 ("f2fs: atomic: fix to not allow GC to pollute > > atomic_file") > > Since original patch has not been merged, if you don't mind, I'd like to > fix t