WSL2-Linux-Kernel/fs/f2fs
Zhiguo Niu 4759856c8b f2fs: fix to do sanity check in update_sit_entry
[ Upstream commit 36959d18c3cf09b3c12157c6950e18652067de77 ]

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:23:26 +02:00
..
Kconfig f2fs: separate out iostat feature 2021-08-23 10:25:51 -07:00
Makefile f2fs: separate out iostat feature 2021-08-23 10:25:51 -07:00
acl.c vfs: add rcu argument to ->get_acl() callback 2021-08-18 22:08:24 +02:00
acl.h vfs: add rcu argument to ->get_acl() callback 2021-08-18 22:08:24 +02:00
checkpoint.c f2fs: fix typos in comments 2024-06-16 13:39:36 +02:00
compress.c f2fs: fix typos in comments 2024-06-16 13:39:36 +02:00
data.c f2fs: fix typos in comments 2024-06-16 13:39:36 +02:00
debug.c f2fs: use spin_lock to avoid hang 2022-04-08 14:23:58 +02:00
dir.c f2fs: don't use casefolded comparison for "." and ".." 2022-06-09 10:23:17 +02:00
extent_cache.c f2fs: fix typos in comments 2024-06-16 13:39:36 +02:00
f2fs.h f2fs: Delete f2fs_copy_page() and replace with memcpy_page() 2024-06-16 13:39:34 +02:00
file.c f2fs: compress: don't allow unaligned truncation on released compress inode 2024-06-16 13:39:40 +02:00
gc.c f2fs: reduce stack memory cost by using bitfield in struct f2fs_io_info 2024-03-26 18:21:32 -04:00
gc.h f2fs: introduce gc_merge mount option 2021-03-30 18:48:56 -07:00
hash.c f2fs: don't use casefolded comparison for "." and ".." 2022-06-09 10:23:17 +02:00
inline.c f2fs: fix return value of f2fs_convert_inline_inode() 2024-08-19 05:44:49 +02:00
inode.c f2fs: fix to don't dirty inode for readonly filesystem 2024-08-19 05:44:49 +02:00
iostat.c f2fs: fix to avoid potential memory corruption in __update_iostat_latency() 2023-03-11 13:57:26 +01:00
iostat.h f2fs: introduce periodic iostat io latency traces 2021-08-23 10:25:51 -07:00
namei.c f2fs: fix typos in comments 2024-06-16 13:39:36 +02:00
node.c f2fs: fix to release node block count in error path of f2fs_new_node_page() 2024-06-16 13:39:39 +02:00
node.h f2fs: swap: support migrating swapfile in aligned write mode 2021-06-23 01:09:35 -07:00
recovery.c f2fs: fix write pointers on zoned device after roll forward 2024-02-23 08:54:46 +01:00
segment.c f2fs: fix to do sanity check in update_sit_entry 2024-09-04 13:23:26 +02:00
segment.h f2fs: apply zone capacity to all zone type 2023-05-11 23:00:27 +09:00
shrinker.c f2fs: avoid race condition for shrinker count 2020-12-03 00:59:26 -08:00
super.c f2fs: remove clear SB_INLINECRYPT flag in default_options 2024-07-05 09:14:28 +02:00
sysfs.c f2fs: fix iostat lock protection 2023-06-14 11:13:00 +02:00
verity.c fs: f2fs: initialize fsdata in pagecache_write() 2023-03-11 13:57:23 +01:00
xattr.c f2fs: explicitly null-terminate the xattr list 2024-01-25 14:52:27 -08:00
xattr.h f2fs: code cleanup by removing ifdef macro surrounding 2020-05-26 18:56:10 -07:00