summaryrefslogtreecommitdiffstats
path: root/fs/ext4/ext4.h
diff options
context:
space:
mode:
authorDmitry Monakhov <dmtrmonakhov@yandex-team.ru>2020-07-25 12:33:13 +0000
committerTheodore Ts'o <tytso@mit.edu>2020-08-07 14:12:36 -0400
commit1cf006ed19a887c22e085189c8b4a3cbf60d2246 (patch)
treeb60311d4d55a7d38acbd8c3b6f535de3c9cfed9c /fs/ext4/ext4.h
parent6dbd300129089ad57de20be89ab7c122b36a4c26 (diff)
downloadlinux-1cf006ed19a887c22e085189c8b4a3cbf60d2246.tar.gz
linux-1cf006ed19a887c22e085189c8b4a3cbf60d2246.tar.bz2
linux-1cf006ed19a887c22e085189c8b4a3cbf60d2246.zip
ext4: export msg_count and warning_count via sysfs
This numbers can be analized by system automation similar to errors_count. In ideal world it would be nice to have separate counters for different log-levels, but this makes this patch too intrusive. Signed-off-by: Dmitry Monakhov <dmtrmonakhov@yandex-team.ru> Link: https://lore.kernel.org/r/20200725123313.4467-1-dmtrmonakhov@yandex-team.ru Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/ext4.h')
-rw-r--r--fs/ext4/ext4.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h
index 32260ceb9cb5..c73b9a1959a9 100644
--- a/fs/ext4/ext4.h
+++ b/fs/ext4/ext4.h
@@ -1591,6 +1591,8 @@ struct ext4_sb_info {
struct ratelimit_state s_err_ratelimit_state;
struct ratelimit_state s_warning_ratelimit_state;
struct ratelimit_state s_msg_ratelimit_state;
+ atomic_t s_warning_count;
+ atomic_t s_msg_count;
/* Encryption context for '-o test_dummy_encryption' */
struct fscrypt_dummy_context s_dummy_enc_ctx;