diff options
| author | Ryusuke Konishi <konishi.ryusuke@gmail.com> | 2025-04-29 02:37:08 +0900 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-06-19 15:40:12 +0200 |
| commit | 1fb0f6aa3e88bf772fe7df580cef2724fae06ca7 (patch) | |
| tree | af98b46a9359f367d68440a9f76cc2919f1ac84e /tools/perf/scripts/python | |
| parent | 46e784bd1d5532d575e4a7a95c35bf6cd2be4ab8 (diff) | |
| download | kernel-1fb0f6aa3e88bf772fe7df580cef2724fae06ca7.tar.gz | |
nilfs2: do not propagate ENOENT error from nilfs_btree_propagate()
[ Upstream commit 8e39fbb1edbb4ec9d7c1124f403877fc167fcecd ]
In preparation for writing logs, in nilfs_btree_propagate(), which makes
parent and ancestor node blocks dirty starting from a modified data block
or b-tree node block, if the starting block does not belong to the b-tree,
i.e. is isolated, nilfs_btree_do_lookup() called within the function
fails with -ENOENT.
In this case, even though -ENOENT is an internal code, it is propagated to
the log writer via nilfs_bmap_propagate() and may be erroneously returned
to system calls such as fsync().
Fix this issue by changing the error code to -EINVAL in this case, and
having the bmap layer detect metadata corruption and convert the error
code appropriately.
Link: https://lkml.kernel.org/r/20250428173808.6452-3-konishi.ryusuke@gmail.com
Fixes: 1f5abe7e7dbc ("nilfs2: replace BUG_ON and BUG calls triggerable from ioctl")
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@gmail.com>
Cc: Wentao Liang <vulab@iscas.ac.cn>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
