summaryrefslogtreecommitdiffstats
path: root/drivers/block
diff options
context:
space:
mode:
authorIlya Dryomov <ilya.dryomov@inktank.com>2014-05-20 15:46:04 +0400
committerYan, Zheng <zheng.z.yan@intel.com>2014-06-06 09:30:00 +0800
commitffe312cf31c7d8616096616d469eb5f6bb8905c0 (patch)
tree4d1203d45b864d6a337c35a65b243d00a24bddea /drivers/block
parent0f2d5be792b0466b06797f637cfbb0f64dbb408c (diff)
downloadop-kernel-dev-ffe312cf31c7d8616096616d469eb5f6bb8905c0.zip
op-kernel-dev-ffe312cf31c7d8616096616d469eb5f6bb8905c0.tar.gz
rbd: fix ida/idr memory leak
ida_destroy() needs to be called on module exit to release ida caches. Signed-off-by: Ilya Dryomov <ilya.dryomov@inktank.com> Reviewed-by: Alex Elder <elder@linaro.org>
Diffstat (limited to 'drivers/block')
-rw-r--r--drivers/block/rbd.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c
index 34a981b..8295b3a 100644
--- a/drivers/block/rbd.c
+++ b/drivers/block/rbd.c
@@ -5473,6 +5473,7 @@ err_out_slab:
static void __exit rbd_exit(void)
{
+ ida_destroy(&rbd_dev_id_ida);
rbd_sysfs_cleanup();
if (single_major)
unregister_blkdev(rbd_major, RBD_DRV_NAME);
OpenPOWER on IntegriCloud