From: Sachin Kamat Date: Fri, 11 Oct 2013 04:41:23 +0000 (+0530) Subject: mtd: plat-ram: Use module_platform_driver X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=98a7c7475d2381febb05d139b5db6f49eeda4427;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git mtd: plat-ram: Use module_platform_driver module_platform_driver simplifies the code by removing boiler plate. Signed-off-by: Sachin Kamat Signed-off-by: Brian Norris --- diff --git a/drivers/mtd/maps/plat-ram.c b/drivers/mtd/maps/plat-ram.c index 3e35b9a330c7..10196f5a897d 100644 --- a/drivers/mtd/maps/plat-ram.c +++ b/drivers/mtd/maps/plat-ram.c @@ -257,21 +257,7 @@ static struct platform_driver platram_driver = { }, }; -/* module init/exit */ - -static int __init platram_init(void) -{ - printk("Generic platform RAM MTD, (c) 2004 Simtec Electronics\n"); - return platform_driver_register(&platram_driver); -} - -static void __exit platram_exit(void) -{ - platform_driver_unregister(&platram_driver); -} - -module_init(platram_init); -module_exit(platram_exit); +module_platform_driver(platram_driver); MODULE_LICENSE("GPL"); MODULE_AUTHOR("Ben Dooks ");