OSDN Git Service

bcache: do not check return value of debugfs_create_dir()
authorColy Li <colyli@suse.de>
Thu, 9 Aug 2018 07:48:42 +0000 (15:48 +0800)
committerJens Axboe <axboe@kernel.dk>
Thu, 9 Aug 2018 14:21:01 +0000 (08:21 -0600)
commit78ac2107176baa0daf65b0fb8e561d2ed14c83ca
tree1569ae7f55d6a742a426a51387c8f0382be2abfc
parenta12fc00b237c25519cc861b56dd4ca41bbec4ed3
bcache: do not check return value of debugfs_create_dir()

Greg KH suggests that normal code should not care about debugfs. Therefore
no matter successful or failed of debugfs_create_dir() execution, it is
unncessary to check its return value.

There are two functions called debugfs_create_dir() and check the return
value, which are bch_debug_init() and closure_debug_init(). This patch
changes these two functions from int to void type, and ignore return values
of debugfs_create_dir().

This patch does not fix exact bug, just makes things work as they should.

Signed-off-by: Coly Li <colyli@suse.de>
Suggested-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: stable@vger.kernel.org
Cc: Kai Krakow <kai@kaishome.de>
Cc: Kent Overstreet <kent.overstreet@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/md/bcache/bcache.h
drivers/md/bcache/closure.c
drivers/md/bcache/closure.h
drivers/md/bcache/debug.c
drivers/md/bcache/super.c