From b8ec61189f3b4cd9d1b2856342f5d7676151d01c Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Tue, 29 Nov 2011 13:56:27 +0800 Subject: watchdog: convert drivers/watchdog/* to use module_platform_driver() This patch converts the drivers in drivers/watchdog/* to use the module_platform_driver() macro which makes the code smaller and a bit simpler. Signed-off-by: Axel Lin Cc: Nicolas Thill Cc: Florian Fainelli Cc: "David S. Miller" Cc: Paul Cercueil Cc: Marc Zyngier Cc: Wan ZongShun Cc: Alejandro Cabrera Cc: "George G. Davis" Cc: Sylver Bruneau Cc: Vitaly Wool Cc: Mika Westerberg Cc: Timo Kokkonen Signed-off-by: Wim Van Sebroeck --- drivers/watchdog/stmp3xxx_wdt.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) (limited to 'drivers/watchdog/stmp3xxx_wdt.c') diff --git a/drivers/watchdog/stmp3xxx_wdt.c b/drivers/watchdog/stmp3xxx_wdt.c index ac2346a452e5..4c2a4e8698f9 100644 --- a/drivers/watchdog/stmp3xxx_wdt.c +++ b/drivers/watchdog/stmp3xxx_wdt.c @@ -272,18 +272,7 @@ static struct platform_driver platform_wdt_driver = { .resume = stmp3xxx_wdt_resume, }; -static int __init stmp3xxx_wdt_init(void) -{ - return platform_driver_register(&platform_wdt_driver); -} - -static void __exit stmp3xxx_wdt_exit(void) -{ - return platform_driver_unregister(&platform_wdt_driver); -} - -module_init(stmp3xxx_wdt_init); -module_exit(stmp3xxx_wdt_exit); +module_platform_driver(platform_wdt_driver); MODULE_DESCRIPTION("STMP3XXX Watchdog Driver"); MODULE_LICENSE("GPL"); -- cgit v1.2.3