Files
linux_media/fs
Ryusuke Konishi 5124a0a549 nilfs2: replace WARN_ONs for invalid DAT metadata block requests
If DAT metadata file block access fails due to corruption of the DAT file
or abnormal virtual block numbers held by b-trees or inodes, a kernel
warning is generated.

This replaces the WARN_ONs by error output, so that a kernel, booted with
panic_on_warn, does not panic.  This patch also replaces the detected
return code -ENOENT with another internal code -EINVAL to notify the bmap
layer of metadata corruption.  When the bmap layer sees -EINVAL, it
handles the abnormal situation with nilfs_bmap_convert_error() and finally
returns code -EIO as it should.

Link: https://lkml.kernel.org/r/0000000000005cc3d205ea23ddcf@google.com
Link: https://lkml.kernel.org/r/20230126164114.6911-1-konishi.ryusuke@gmail.com
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
Reported-by: <syzbot+5d5d25f90f195a3cfcb4@syzkaller.appspotmail.com>
Tested-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2023-02-02 22:50:08 -08:00
..
2022-12-11 18:12:18 -08:00
2022-10-20 10:13:27 +02:00
2022-09-24 07:00:00 +02:00
2022-12-11 18:12:18 -08:00
2022-05-09 16:21:46 -04:00
2023-01-06 15:44:32 +01:00
2022-09-11 20:26:07 -07:00
2023-01-05 07:34:21 -08:00
2022-11-25 17:01:22 +09:00
2022-10-20 10:13:27 +02:00
2022-08-20 11:34:33 -04:00
2022-12-11 18:12:17 -08:00
2022-12-21 14:45:25 +01:00
2022-06-28 13:58:05 -04:00
2022-10-26 10:02:34 +02:00