projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d5fcc4e
)
drivers/block/aoe/aoedev: NULL check is not needed for mempool_destroy
author
zhong jiang
<zhongjiang@huawei.com>
Wed, 8 Aug 2018 15:00:35 +0000
(23:00 +0800)
committer
Jens Axboe
<axboe@kernel.dk>
Wed, 8 Aug 2018 15:17:20 +0000
(09:17 -0600)
mempool_destroy has taken the null pointer into account. So it is safe
to remove the null check.
Signed-off-by: zhong jiang <zhongjiang@huawei.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/aoe/aoedev.c
patch
|
blob
|
history
diff --git
a/drivers/block/aoe/aoedev.c
b/drivers/block/aoe/aoedev.c
index 697f735b07a435da967332511f9673258e6eee88..41060e9cedf20c882816c1c83ca21e15512152a2 100644
(file)
--- a/
drivers/block/aoe/aoedev.c
+++ b/
drivers/block/aoe/aoedev.c
@@
-284,8
+284,8
@@
freedev(struct aoedev *d)
e = t + d->ntargets;
for (; t < e && *t; t++)
freetgt(d, *t);
- if (d->bufpool)
-
mempool_destroy(d->bufpool);
+
+ mempool_destroy(d->bufpool);
skbpoolfree(d);
minor_free(d->sysminor);