From: Axel Lin Date: Fri, 17 Jun 2011 11:06:33 +0000 (+0800) Subject: mtd: onenand: remove redundant mtd_device_unregister before onenand_release X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e638275e18a929103bb087acb94d2b67eb0818e0;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git mtd: onenand: remove redundant mtd_device_unregister before onenand_release onenand_release() will call mtd_device_unregister(), thus remove the redundant mtd_device_unregister() call before onenand_release(). Signed-off-by: Axel Lin Signed-off-by: Artem Bityutskiy --- diff --git a/drivers/mtd/onenand/generic.c b/drivers/mtd/onenand/generic.c index 8152a3160b12..7813095264a5 100644 --- a/drivers/mtd/onenand/generic.c +++ b/drivers/mtd/onenand/generic.c @@ -97,7 +97,6 @@ static int __devexit generic_onenand_remove(struct platform_device *pdev) platform_set_drvdata(pdev, NULL); if (info) { - mtd_device_unregister(&info->mtd); onenand_release(&info->mtd); release_mem_region(res->start, size); iounmap(info->onenand.base);