All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] watchdog: ath79_wdt: convert to use module_platform_driver
@ 2012-08-14 13:35 Gabor Juhos
  2012-11-14 10:43 ` Gabor Juhos
  0 siblings, 1 reply; 2+ messages in thread
From: Gabor Juhos @ 2012-08-14 13:35 UTC (permalink / raw)
  To: Wim Van Sebroeck; +Cc: linux-watchdog, Gabor Juhos

This makes the code a bit smaller by getting rid of
some boilerplate code.

Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
---
 drivers/watchdog/ath79_wdt.c |   13 ++-----------
 1 file changed, 2 insertions(+), 11 deletions(-)

diff --git a/drivers/watchdog/ath79_wdt.c b/drivers/watchdog/ath79_wdt.c
index 1f9371f..79cc407 100644
--- a/drivers/watchdog/ath79_wdt.c
+++ b/drivers/watchdog/ath79_wdt.c
@@ -284,6 +284,7 @@ static void ath97_wdt_shutdown(struct platform_device *pdev)
 }
 
 static struct platform_driver ath79_wdt_driver = {
+	.probe		= ath79_wdt_probe,
 	.remove		= __devexit_p(ath79_wdt_remove),
 	.shutdown	= ath97_wdt_shutdown,
 	.driver		= {
@@ -292,17 +293,7 @@ static struct platform_driver ath79_wdt_driver = {
 	},
 };
 
-static int __init ath79_wdt_init(void)
-{
-	return platform_driver_probe(&ath79_wdt_driver, ath79_wdt_probe);
-}
-module_init(ath79_wdt_init);
-
-static void __exit ath79_wdt_exit(void)
-{
-	platform_driver_unregister(&ath79_wdt_driver);
-}
-module_exit(ath79_wdt_exit);
+module_platform_driver(ath79_wdt_driver);
 
 MODULE_DESCRIPTION("Atheros AR71XX/AR724X/AR913X hardware watchdog driver");
 MODULE_AUTHOR("Gabor Juhos <juhosg@openwrt.org");
-- 
1.7.10


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] watchdog: ath79_wdt: convert to use module_platform_driver
  2012-08-14 13:35 [PATCH] watchdog: ath79_wdt: convert to use module_platform_driver Gabor Juhos
@ 2012-11-14 10:43 ` Gabor Juhos
  0 siblings, 0 replies; 2+ messages in thread
From: Gabor Juhos @ 2012-11-14 10:43 UTC (permalink / raw)
  To: Gabor Juhos; +Cc: Wim Van Sebroeck, linux-watchdog

2012.08.14. 15:35 keltezéssel, Gabor Juhos írta:
> This makes the code a bit smaller by getting rid of
> some boilerplate code.
> 
> Signed-off-by: Gabor Juhos <juhosg@openwrt.org>

Ping?
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-11-14 10:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-14 13:35 [PATCH] watchdog: ath79_wdt: convert to use module_platform_driver Gabor Juhos
2012-11-14 10:43 ` Gabor Juhos

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.