From: Anand Jain <anand.jain@oracle.com>
To: linux-btrfs@vger.kernel.org
Cc: Wolfgang_Mader@brain-frog.de, dsterba@suse.cz
Subject: [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid
Date: Mon, 27 Apr 2015 12:46:19 +0800 [thread overview]
Message-ID: <1430109979-9397-3-git-send-email-anand.jain@oracle.com> (raw)
In-Reply-To: <1430109979-9397-1-git-send-email-anand.jain@oracle.com>
Report missing device when add is successful,
otherwise it would exit as ENOMEM. And add uuid
to the report.
Signed-off-by: Anand Jain <anand.jain@oracle.com>
---
fs/btrfs/volumes.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index 693745e..d722ee5 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -6255,10 +6255,11 @@ static int read_one_dev(struct btrfs_root *root,
if (!btrfs_test_opt(root, DEGRADED))
return -EIO;
- btrfs_warn(root->fs_info, "devid %llu missing", devid);
device = add_missing_dev(root, fs_devices, devid, dev_uuid);
if (!device)
return -ENOMEM;
+ btrfs_warn(root->fs_info, "devid %llu uuid %pU missing",
+ devid, uuid);
} else {
if (!device->bdev && !btrfs_test_opt(root, DEGRADED))
return -EIO;
--
2.0.0.153.g79dcccc
next prev parent reply other threads:[~2015-04-27 4:49 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-27 4:46 [PATCH 0/2] serviceability: add event log when missing device is created Anand Jain
2015-04-27 4:46 ` [PATCH 1/2] Btrfs: " Anand Jain
2015-05-05 15:52 ` David Sterba
2015-04-27 4:46 ` Anand Jain [this message]
2015-05-05 15:43 ` [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid David Sterba
2015-05-07 20:34 ` Anand Jain
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=1430109979-9397-3-git-send-email-anand.jain@oracle.com \
--to=anand.jain@oracle.com \
--cc=Wolfgang_Mader@brain-frog.de \
--cc=dsterba@suse.cz \
--cc=linux-btrfs@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).