diff options
author | Jan Kara <jack@suse.cz> | 2017-09-06 06:25:51 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-09-27 12:39:24 (GMT) |
commit | c234e0e77572d78cbac0de7acee2263343595c25 (patch) | |
tree | e3e4af972f511f3741e62767746ffe2654ff9fb3 /kernel | |
parent | 2a9b55742a9fe838ddc86f8b5c75a56867ea1912 (diff) | |
download | linux-c234e0e77572d78cbac0de7acee2263343595c25.tar.xz |
bcache: Fix leak of bdev reference
commit 4b758df21ee7081ab41448d21d60367efaa625b3 upstream.
If blkdev_get_by_path() in register_bcache() fails, we try to lookup the
block device using lookup_bdev() to detect which situation we are in to
properly report error. However we never drop the reference returned to
us from lookup_bdev(). Fix that.
Signed-off-by: Jan Kara <jack@suse.cz>
Acked-by: Coly Li <colyli@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel')
0 files changed, 0 insertions, 0 deletions