From: Yi Li <yili@winhong.com>
To: colyli@suse.de
Cc: yilikernel@gmail.com, kent.overstreet@gmail.com,
linux-bcache@vger.kernel.org, linux-kernel@vger.kernel.org,
Yi Li <yili@winhong.com>
Subject: [PATCH] bcache: Trivial fix to bdput
Date: Mon, 21 Dec 2020 11:17:39 +0800 [thread overview]
Message-ID: <20201221031739.563404-1-yili@winhong.com> (raw)
Trivial fix to bdput.
Signed-off-by: Yi Li <yili@winhong.com>
---
drivers/md/bcache/super.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c
index f7ad1e26b013..1756f6926098 100644
--- a/drivers/md/bcache/super.c
+++ b/drivers/md/bcache/super.c
@@ -2525,8 +2525,8 @@ static ssize_t register_bcache(struct kobject *k, struct kobj_attribute *attr,
else
err = "device busy";
mutex_unlock(&bch_register_lock);
- if (!IS_ERR(bdev))
- bdput(bdev);
+ if (!IS_ERR(dev))
+ bdput(dev);
if (attr == &ksysfs_register_quiet)
goto done;
}
--
2.25.3
next reply other threads:[~2020-12-21 3:23 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-21 3:17 Yi Li [this message]
2020-12-21 5:48 ` [PATCH v2] bcache: Trivial fix to register_bcache Yi Li
2020-12-21 7:35 ` [PATCH] bcache: Trivial fix to bdput Coly Li
2020-12-21 9:49 ` [PATCH v4] bcache:remove a superfluous check in register_bcache Yi Li
2020-12-23 8:58 ` 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=20201221031739.563404-1-yili@winhong.com \
--to=yili@winhong.com \
--cc=colyli@suse.de \
--cc=kent.overstreet@gmail.com \
--cc=linux-bcache@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=yilikernel@gmail.com \
/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).