From: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: liu.song.a23@gmail.com,
Marcos Paulo de Souza <marcos.souza.org@gmail.com>,
Shaohua Li <shli@kernel.org>,
"open list:SOFTWARE RAID Multiple Disks SUPPORT"
<linux-raid@vger.kernel.org>
Subject: [PATCH] md: md.c: Return -ENODEV when mddev is NULL in rdev_attr_show
Date: Thu, 23 May 2019 23:44:59 -0300 [thread overview]
Message-ID: <20190524024459.6875-1-marcos.souza.org@gmail.com> (raw)
Commit c42d3240990814eec1e4b2b93fa0487fc4873aed
("md: return -ENODEV if rdev has no mddev assigned") changed rdev_attr_store to
return -ENODEV when rdev->mddev is NULL, now do the same to rdev_attr_show.
Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
---
drivers/md/md.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/md/md.c b/drivers/md/md.c
index 45ffa23fa85d..0b391e7e063b 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -3363,7 +3363,7 @@ rdev_attr_show(struct kobject *kobj, struct attribute *attr, char *page)
if (!entry->show)
return -EIO;
if (!rdev->mddev)
- return -EBUSY;
+ return -ENODEV;
return entry->show(rdev, page);
}
--
2.21.0
next reply other threads:[~2019-05-24 2:44 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-24 2:44 Marcos Paulo de Souza [this message]
2019-06-06 16:41 ` [PATCH] md: md.c: Return -ENODEV when mddev is NULL in rdev_attr_show Song Liu
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=20190524024459.6875-1-marcos.souza.org@gmail.com \
--to=marcos.souza.org@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-raid@vger.kernel.org \
--cc=liu.song.a23@gmail.com \
--cc=shli@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