]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
f2fs: do not allow partial truncation on pinned file
authorJaegeuk Kim <jaegeuk@kernel.org>
Sat, 8 Jan 2022 04:08:45 +0000 (20:08 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 16 Jun 2024 11:39:36 +0000 (13:39 +0200)
commit603c0c3a83fc24b793d6912b8971e7d4932f3a16
tree10fb8db10b84be930c588d359159fe98e94aafcf
parent4f0750bf8a3310e9a7effea9ed021dc8d1655a56
f2fs: do not allow partial truncation on pinned file

[ Upstream commit 5fed0be8583f08c1548b4dcd9e5ee0d1133d0730 ]

If the pinned file has a hole by partial truncation, application that has
the block map will be broken.

Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Stable-dep-of: 278a6253a673 ("f2fs: fix to relocate check condition in f2fs_fallocate()")
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/f2fs/file.c