Files
twx-linux/fs/f2fs
Zhiguo Niu 3c2c864f19 f2fs: fix to do sanity check in update_sit_entry
[ Upstream commit 36959d18c3 ]

If GET_SEGNO return NULL_SEGNO for some unecpected case,
update_sit_entry will access invalid memory address,
cause system crash. It is better to do sanity check about
GET_SEGNO just like update_segment_mtime & locate_dirty_segment.

Also remove some redundant judgment code.

Signed-off-by: Zhiguo Niu <zhiguo.niu@unisoc.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-09-04 13:13:03 +02:00
..
2024-01-25 14:33:35 -08:00