From: Ilya Dryomov Date: Tue, 20 May 2014 11:46:04 +0000 (+0400) Subject: rbd: fix ida/idr memory leak X-Git-Tag: firefly_0821_release~176^2~3753^2~5 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=ffe312cf31c7d8616096616d469eb5f6bb8905c0;p=firefly-linux-kernel-4.4.55.git rbd: fix ida/idr memory leak ida_destroy() needs to be called on module exit to release ida caches. Signed-off-by: Ilya Dryomov Reviewed-by: Alex Elder --- diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c index 34a981ba1b9e..8295b3afa8e0 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);