From: Jingoo Han Date: Tue, 26 Mar 2013 23:25:20 +0000 (+1100) Subject: rtc: rtc-sh: use module_platform_driver_probe() X-Git-Tag: next-20130404~3^2~243 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=0f4df4634286e1d1d510dd1231673554c1257c12;p=karo-tx-linux.git rtc: rtc-sh: use module_platform_driver_probe() Use module_platform_driver_probe() macro which makes the code smaller and simpler. Signed-off-by: Jingoo Han Acked-by: Paul Mundt Signed-off-by: Andrew Morton --- diff --git a/drivers/rtc/rtc-sh.c b/drivers/rtc/rtc-sh.c index e55a7635ae5f..5f4708522f4d 100644 --- a/drivers/rtc/rtc-sh.c +++ b/drivers/rtc/rtc-sh.c @@ -820,18 +820,7 @@ static struct platform_driver sh_rtc_platform_driver = { .remove = __exit_p(sh_rtc_remove), }; -static int __init sh_rtc_init(void) -{ - return platform_driver_probe(&sh_rtc_platform_driver, sh_rtc_probe); -} - -static void __exit sh_rtc_exit(void) -{ - platform_driver_unregister(&sh_rtc_platform_driver); -} - -module_init(sh_rtc_init); -module_exit(sh_rtc_exit); +module_platform_driver_probe(sh_rtc_platform_driver, sh_rtc_probe); MODULE_DESCRIPTION("SuperH on-chip RTC driver"); MODULE_VERSION(DRV_VERSION);