diff options
author | Geert Uytterhoeven <geert+renesas@glider.be> | 2020-08-14 13:07:31 +0200 |
---|---|---|
committer | Alexandre Belloni <alexandre.belloni@bootlin.com> | 2020-08-21 00:13:44 +0200 |
commit | 163a512cd929d6db712a3021720362749653998b (patch) | |
tree | 94be1859e6e81f8579e4853167803c0ae7375f8b | |
parent | f65e727464d7c0090f05548e8f323779eaa97eda (diff) |
rtc: rtc-rs5c313: Convert to module_platform_driver()
Reduce boilerplate by using the module_platform_driver() helper.
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/r/20200814110731.29029-4-geert+renesas@glider.be
-rw-r--r-- | drivers/rtc/rtc-rs5c313.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/rtc/rtc-rs5c313.c b/drivers/rtc/rtc-rs5c313.c index af72e428b218..e98f85f34206 100644 --- a/drivers/rtc/rtc-rs5c313.c +++ b/drivers/rtc/rtc-rs5c313.c @@ -384,18 +384,7 @@ static struct platform_driver rs5c313_rtc_platform_driver = { .probe = rs5c313_rtc_probe, }; -static int __init rs5c313_rtc_init(void) -{ - return platform_driver_register(&rs5c313_rtc_platform_driver); -} - -static void __exit rs5c313_rtc_exit(void) -{ - platform_driver_unregister(&rs5c313_rtc_platform_driver); -} - -module_init(rs5c313_rtc_init); -module_exit(rs5c313_rtc_exit); +module_platform_driver(rs5c313_rtc_platform_driver); MODULE_AUTHOR("kogiidena , Nobuhiro Iwamatsu <iwamatsu@nigauri.org>"); MODULE_DESCRIPTION("Ricoh RS5C313 RTC device driver"); |