diff options
author | Jingoo Han <jg1.han@samsung.com> | 2013-04-29 19:18:51 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-04-29 21:28:24 -0400 |
commit | deed5a9dc94cf375d4cdd4330b34fcdfc0e41a74 (patch) | |
tree | d5e03cd1cfa3eb93c3bbf5475bcacb966ba4e8e7 | |
parent | 9842eaff052e0a5f5937108d72ad5a91c86dca6d (diff) |
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 <jg1.han@samsung.com>
Acked-by: Paul Mundt <lethal@linux-sh.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | drivers/rtc/rtc-sh.c | 13 |
1 files changed, 1 insertions, 12 deletions
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 = { | |||
820 | .remove = __exit_p(sh_rtc_remove), | 820 | .remove = __exit_p(sh_rtc_remove), |
821 | }; | 821 | }; |
822 | 822 | ||
823 | static int __init sh_rtc_init(void) | 823 | module_platform_driver_probe(sh_rtc_platform_driver, sh_rtc_probe); |
824 | { | ||
825 | return platform_driver_probe(&sh_rtc_platform_driver, sh_rtc_probe); | ||
826 | } | ||
827 | |||
828 | static void __exit sh_rtc_exit(void) | ||
829 | { | ||
830 | platform_driver_unregister(&sh_rtc_platform_driver); | ||
831 | } | ||
832 | |||
833 | module_init(sh_rtc_init); | ||
834 | module_exit(sh_rtc_exit); | ||
835 | 824 | ||
836 | MODULE_DESCRIPTION("SuperH on-chip RTC driver"); | 825 | MODULE_DESCRIPTION("SuperH on-chip RTC driver"); |
837 | MODULE_VERSION(DRV_VERSION); | 826 | MODULE_VERSION(DRV_VERSION); |