diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-12-07 11:24:00 -0500 |
---|---|---|
committer | Grant Likely <grant.likely@secretlab.ca> | 2012-01-02 02:26:06 -0500 |
commit | 6f61415e9c4c0ab02c8eda7671bb652db4863cc0 (patch) | |
tree | 689e7f50b2d6de5a5a36d72b2ba72a742d39341c /drivers/gpio/gpio-timberdale.c | |
parent | f134759955bbb5bf28a8d2c6fe5aa201d1ffb860 (diff) |
gpio: Convert GPIO drivers to module_platform_driver
Where appropriate factor out some boilerplate code for platform device
registration into module_platform_driver. Drivers that don't use the
standard module_init initcall haven't been converted.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'drivers/gpio/gpio-timberdale.c')
-rw-r--r-- | drivers/gpio/gpio-timberdale.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/gpio/gpio-timberdale.c b/drivers/gpio/gpio-timberdale.c index c593bd46bfb..031c6adf5b6 100644 --- a/drivers/gpio/gpio-timberdale.c +++ b/drivers/gpio/gpio-timberdale.c | |||
@@ -359,18 +359,7 @@ static struct platform_driver timbgpio_platform_driver = { | |||
359 | 359 | ||
360 | /*--------------------------------------------------------------------------*/ | 360 | /*--------------------------------------------------------------------------*/ |
361 | 361 | ||
362 | static int __init timbgpio_init(void) | 362 | module_platform_driver(timbgpio_platform_driver); |
363 | { | ||
364 | return platform_driver_register(&timbgpio_platform_driver); | ||
365 | } | ||
366 | |||
367 | static void __exit timbgpio_exit(void) | ||
368 | { | ||
369 | platform_driver_unregister(&timbgpio_platform_driver); | ||
370 | } | ||
371 | |||
372 | module_init(timbgpio_init); | ||
373 | module_exit(timbgpio_exit); | ||
374 | 363 | ||
375 | MODULE_DESCRIPTION("Timberdale GPIO driver"); | 364 | MODULE_DESCRIPTION("Timberdale GPIO driver"); |
376 | MODULE_LICENSE("GPL v2"); | 365 | MODULE_LICENSE("GPL v2"); |