aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorJan Luebbe2013-07-03 15:09:10 -0700
committerLinus Torvalds2013-07-03 16:08:06 -0700
commit05212be363363efbc003d4fa1eaf8e48dfbe425a (patch)
treeef0dbffbc8ae5b31f80b602a7b6f3e0432176399 /drivers
parent2a65182235790fc9a6abb9f41c1006c95f506545 (diff)
drivers/pps/clients/pps-gpio.c: convert to module_platform_driver
This removes some boilerplate code (no functional changes). Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Acked-by: Rodolfo Giometti <giometti@enneenne.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/pps/clients/pps-gpio.c18
1 files changed, 1 insertions, 17 deletions
diff --git a/drivers/pps/clients/pps-gpio.c b/drivers/pps/clients/pps-gpio.c
index 54c2809021a3..5bd3bf093b54 100644
--- a/drivers/pps/clients/pps-gpio.c
+++ b/drivers/pps/clients/pps-gpio.c
@@ -187,23 +187,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@fe.up.pt>");
MODULE_AUTHOR("James Nuss <jamesnuss@nanometrics.ca>");
MODULE_DESCRIPTION("Use GPIO pin as PPS source");