Skip to content

Commit

Permalink
rtc: rtc-at32ap700x: use module_platform_driver_probe()
Browse files Browse the repository at this point in the history
Use module_platform_driver_probe() macro which makes the code smaller and
simpler.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Jingoo Han authored and Linus Torvalds committed Apr 30, 2013
1 parent fb34a81 commit e835ebc
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions drivers/rtc/rtc-at32ap700x.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,17 +302,7 @@ static struct platform_driver at32_rtc_driver = {
},
};

static int __init at32_rtc_init(void)
{
return platform_driver_probe(&at32_rtc_driver, at32_rtc_probe);
}
module_init(at32_rtc_init);

static void __exit at32_rtc_exit(void)
{
platform_driver_unregister(&at32_rtc_driver);
}
module_exit(at32_rtc_exit);
module_platform_driver_probe(at32_rtc_driver, at32_rtc_probe);

MODULE_AUTHOR("Hans-Christian Egtvedt <hcegtvedt@atmel.com>");
MODULE_DESCRIPTION("Real time clock for AVR32 AT32AP700x");
Expand Down

0 comments on commit e835ebc

Please sign in to comment.