lkml.org 
[lkml]   [2020]   [Dec]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] bcache: Trivial fix to bdput
Date
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


\
 
 \ /
  Last update: 2020-12-21 04:25    [W:0.061 / U:3.876 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site