From: Qu Wenruo <wqu@suse.com>
To: linux-btrfs@vger.kernel.org, linux-block@vger.kernel.org,
linux-fsdevel@vger.kernel.org
Subject: [PATCH v2 2/2] btrfs: Add error string for EUCLEAN
Date: Sat, 6 Apr 2019 18:37:59 +0800 [thread overview]
Message-ID: <20190406103759.6330-2-wqu@suse.com> (raw)
In-Reply-To: <20190406103759.6330-1-wqu@suse.com>
Since we're going to support write time tree checker, it's possible that
transaction get aborted due to tree-checker, also due to new
BLK_STS_UCLEAN bit, we can distinguish real EIO error and EUCLEAN
error.
So adding new string for EUCLEAN to make the "unknown" reason to an easy
to read one.
Signed-off-by: Qu Wenruo <wqu@suse.com>
---
changelog:
v2:
- Use the original error message from EUCLEAN.
---
fs/btrfs/super.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c
index 120e4340792a..f69a6696f59d 100644
--- a/fs/btrfs/super.c
+++ b/fs/btrfs/super.c
@@ -86,6 +86,9 @@ const char *btrfs_decode_error(int errno)
case -ENOENT:
errstr = "No such entry";
break;
+ case -EUCLEAN:
+ errstr = "Structure needs cleaning";
+ break;
}
return errstr;
--
2.21.0
next prev parent reply other threads:[~2019-04-06 10:38 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-06 10:37 [PATCH v2 1/2] block: Add new BLK_STS_SELFTEST status Qu Wenruo
2019-04-06 10:37 ` Qu Wenruo [this message]
2019-04-07 7:04 ` Christoph Hellwig
2019-04-07 7:08 ` Qu Wenruo
2019-04-08 6:32 ` Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190406103759.6330-2-wqu@suse.com \
--to=wqu@suse.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-btrfs@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).