diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2022-01-11 22:08:44 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:09:23 -0400 |
commit | b74b147ddabe29a91a00d9f2cefeb6892e6a5a0a (patch) | |
tree | dc11ba601f4994a991f04d92ec0f54c515e2b5fa /fs/bcachefs/error.c | |
parent | 54460a6292b08a8045d8681ac4331dfb9c385017 (diff) | |
download | lwn-b74b147ddabe29a91a00d9f2cefeb6892e6a5a0a.tar.gz lwn-b74b147ddabe29a91a00d9f2cefeb6892e6a5a0a.zip |
bcachefs: Log message improvements
Change the error messages in bch2_inconsistent_error() and
bch2_fatal_error() so we can distinguish them.
Also, prefer bch2_fs_fatal_error() (which also logs an error message) to
bch2_fatal_error(), and change a call to bch2_inconsistent_error() to
bch2_fatal_error() when we can't continue.
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Diffstat (limited to 'fs/bcachefs/error.c')
-rw-r--r-- | fs/bcachefs/error.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/bcachefs/error.c b/fs/bcachefs/error.c index 2cea694575e9..8279a9ba76a5 100644 --- a/fs/bcachefs/error.c +++ b/fs/bcachefs/error.c @@ -15,7 +15,7 @@ bool bch2_inconsistent_error(struct bch_fs *c) return false; case BCH_ON_ERROR_ro: if (bch2_fs_emergency_read_only(c)) - bch_err(c, "emergency read only"); + bch_err(c, "inconsistency detected - emergency read only"); return true; case BCH_ON_ERROR_panic: panic(bch2_fmt(c, "panic after error")); @@ -35,7 +35,7 @@ void bch2_topology_error(struct bch_fs *c) void bch2_fatal_error(struct bch_fs *c) { if (bch2_fs_emergency_read_only(c)) - bch_err(c, "emergency read only"); + bch_err(c, "fatal error - emergency read only"); } void bch2_io_error_work(struct work_struct *work) |