]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
f2fs: compress: fix to guarantee persisting compressed blocks by CP
authorChao Yu <chao@kernel.org>
Fri, 12 Jan 2024 19:41:27 +0000 (03:41 +0800)
committerSasha Levin <sashal@kernel.org>
Tue, 26 Mar 2024 22:19:58 +0000 (18:19 -0400)
commit82704e598d7b33c7e45526e34d3c585426319bed
treedaf2fe207d18d166882b733e003449e085082077
parent85570b91e4820a0db9d9432098778cafafa7d217
f2fs: compress: fix to guarantee persisting compressed blocks by CP

[ Upstream commit 8a430dd49e9cb021372b0ad91e60aeef9c6ced00 ]

If data block in compressed cluster is not persisted with metadata
during checkpoint, after SPOR, the data may be corrupted, let's
guarantee to write compressed page by checkpoint.

Fixes: 4c8ff7095bef ("f2fs: support data compression")
Reviewed-by: Daeho Jeong <daehojeong@google.com>
Signed-off-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/f2fs/compress.c
fs/f2fs/data.c
fs/f2fs/f2fs.h