Commit 4078def8 authored by Tim Hansen's avatar Tim Hansen Committed by Jens Axboe

block/bio: Remove null checks before mempool_destroy in bioset_free

This patch removes redundant checks for null values on bio_pool and
bvec_pool.

Found using make coccicheck M=block/ on linux-net tree on the
next-20170929 tag.
Signed-off-by: default avatarTim Hansen <devtimhansen@gmail.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 4b14a5c5
......@@ -1928,10 +1928,7 @@ void bioset_free(struct bio_set *bs)
if (bs->rescue_workqueue)
destroy_workqueue(bs->rescue_workqueue);
if (bs->bio_pool)
mempool_destroy(bs->bio_pool);
if (bs->bvec_pool)
mempool_destroy(bs->bvec_pool);
bioset_integrity_free(bs);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment