[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <1366980469-6763-2-git-send-email-jlu@pengutronix.de>
Date: Fri, 26 Apr 2013 14:47:49 +0200
From: Jan Luebbe <jlu@...gutronix.de>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: Rodolfo Giometti <giometti@...eenne.com>,
linux-kernel@...r.kernel.org, Jan Luebbe <jlu@...gutronix.de>
Subject: [PATCH 2/2] pps-gpio: convert to module_platform_driver
This removes some boilerplate code (no functional changes).
Signed-off-by: Jan Luebbe <jlu@...gutronix.de>
Acked-by: Rodolfo Giometti <giometti@...eenne.com>
---
drivers/pps/clients/pps-gpio.c | 18 +-----------------
1 file changed, 1 insertion(+), 17 deletions(-)
diff --git a/drivers/pps/clients/pps-gpio.c b/drivers/pps/clients/pps-gpio.c
index 221858d..6768f95 100644
--- a/drivers/pps/clients/pps-gpio.c
+++ b/drivers/pps/clients/pps-gpio.c
@@ -188,23 +188,7 @@ static struct platform_driver pps_gpio_driver = {
},
};
-static int __init pps_gpio_init(void)
-{
- int ret = platform_driver_register(&pps_gpio_driver);
- if (ret < 0)
- pr_err("failed to register platform driver\n");
- return ret;
-}
-
-static void __exit pps_gpio_exit(void)
-{
- platform_driver_unregister(&pps_gpio_driver);
- pr_debug("unregistered platform driver\n");
-}
-
-module_init(pps_gpio_init);
-module_exit(pps_gpio_exit);
-
+module_platform_driver(pps_gpio_driver);
MODULE_AUTHOR("Ricardo Martins <rasm@...up.pt>");
MODULE_AUTHOR("James Nuss <jamesnuss@...ometrics.ca>");
MODULE_DESCRIPTION("Use GPIO pin as PPS source");
--
1.7.10.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists