]> www.infradead.org Git - users/jedix/linux-maple.git/commit
f2fs: add a proc entry show inject stats
authorChao Yu <chao@kernel.org>
Thu, 20 Mar 2025 02:22:29 +0000 (10:22 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Thu, 10 Apr 2025 03:59:57 +0000 (03:59 +0000)
commite073e92789839d10a8828c13f9fe47ee517aa8e6
treed8a2982375177b2e2d96bfc1543cbe7f075a6e7d
parent539d33455f96532ac88115c35b1769db966003c6
f2fs: add a proc entry show inject stats

This patch adds a proc entry named inject_stats to show total injected
count for each fault type.

cat /proc/fs/f2fs/<dev>/inject_stats
fault_type              injected_count
kmalloc                 0
kvmalloc                0
page alloc              0
page get                0
alloc bio(obsolete)     0
alloc nid               0
orphan                  0
no more block           0
too big dir depth       0
evict_inode fail        0
truncate fail           0
read IO error           0
checkpoint error        0
discard error           0
write IO error          0
slab alloc              0
dquot initialize        0
lock_op                 0
invalid blkaddr         0
inconsistent blkaddr    0
no free segment         0
inconsistent footer     0

Signed-off-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/f2fs.h
fs/f2fs/super.c
fs/f2fs/sysfs.c