Signed-off-by: Jaegeuk Kim
---
Change log from v1:
- check the negative values
fsck/inject.c | 26 +++---
1 file changed, 15 insertions(+), 11 deletions(-)
diff --git a/fsck/inject.c b/fsck/inject.c
index 2a21dae293f6..9dc085f389be 100644
--- a/fsck/inject.c
+++
On 07/30, Chao Yu wrote:
> On 2024/7/30 0:26, Jaegeuk Kim wrote:
> > On 07/26, Chao Yu wrote:
> > > We should always truncate pagecache while truncating on-disk data.
> > >
> > > Fixes: a46bebd502fe ("f2fs: synchronize atomic write aborts")
> > > Signed-off-by: Chao Yu
> > > ---
> > > v2:
> > >
From: Chao Yu
[ Upstream commit fc01008c92f40015aeeced94750855a7111b6929 ]
syzbot reports a f2fs bug as below:
[ cut here ]
kernel BUG at fs/f2fs/inline.c:258!
CPU: 1 PID: 34 Comm: kworker/u8:2 Not tainted
6.9.0-rc6-syzkaller-00012-g9e4bc4bcae01 #0
RIP:
From: Chao Yu
[ Upstream commit fc01008c92f40015aeeced94750855a7111b6929 ]
syzbot reports a f2fs bug as below:
[ cut here ]
kernel BUG at fs/f2fs/inline.c:258!
CPU: 1 PID: 34 Comm: kworker/u8:2 Not tainted
6.9.0-rc6-syzkaller-00012-g9e4bc4bcae01 #0
RIP:
From: Chao Yu
[ Upstream commit c240c87bcd44a1a2375fc8ef8c645d1f1fe76466 ]
inode can be fuzzed, so it can has F2FS_INLINE_DATA flag and valid
i_blocks/i_nid value, this patch supports to do extra sanity check
to detect such corrupted state.
Signed-off-by: Chao Yu
Signed-off-by: Jaegeuk Kim
From: Chao Yu
[ Upstream commit d7409b05a64f212735f0d33f5f1602051a886eab ]
syzbot reports a f2fs bug as below:
BUG: KASAN: slab-use-after-free in sanity_check_extent_cache+0x370/0x410
fs/f2fs/extent_cache.c:46
Read of size 4 at addr 8880739ab220 by task syz-executor200/5097
CPU: 0 PID:
From: Chao Yu
[ Upstream commit d7409b05a64f212735f0d33f5f1602051a886eab ]
syzbot reports a f2fs bug as below:
BUG: KASAN: slab-use-after-free in sanity_check_extent_cache+0x370/0x410
fs/f2fs/extent_cache.c:46
Read of size 4 at addr 8880739ab220 by task syz-executor200/5097
CPU: 0 PID:
From: Chao Yu
[ Upstream commit c240c87bcd44a1a2375fc8ef8c645d1f1fe76466 ]
inode can be fuzzed, so it can has F2FS_INLINE_DATA flag and valid
i_blocks/i_nid value, this patch supports to do extra sanity check
to detect such corrupted state.
Signed-off-by: Chao Yu
Signed-off-by: Jaegeuk Kim
On Mon 29-07-24 09:58:47, Theodore Ts'o wrote:
> On Mon, Jul 29, 2024 at 03:27:21PM +0200, Jan Kara wrote:
> > So in ext4 we have EXT4_FLAGS_SHUTDOWN flag which we now use
> > internally instead of SB_RDONLY flag for checking whether the
> > filesystem was shutdown (because otherwise races between