misc: sram: cleanup the code
authorXiubo Li <Li.Xiubo@freescale.com>
Wed, 15 Jan 2014 03:16:35 +0000 (11:16 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 7 Feb 2014 23:10:19 +0000 (15:10 -0800)
Since the devm_gen_pool_create() is used, so the gen_pool_destroy()
here is redundant.

Signed-off-by: Xiubo Li <Li.Xiubo@freescale.com>
Acked-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/misc/sram.c

index afe66571ce0b7bfde98f05a1a75175f250482fa5..e3e421d97ad4b7be5d9be9c2b8ad5ddd192f4f9a 100644 (file)
@@ -87,8 +87,6 @@ static int sram_remove(struct platform_device *pdev)
        if (gen_pool_avail(sram->pool) < gen_pool_size(sram->pool))
                dev_dbg(&pdev->dev, "removed while SRAM allocated\n");
 
-       gen_pool_destroy(sram->pool);
-
        if (sram->clk)
                clk_disable_unprepare(sram->clk);