summaryrefslogtreecommitdiffstats
path: root/drivers/mfd/twl4030-audio.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2011-11-23 22:58:34 +0000
committerSamuel Ortiz <sameo@linux.intel.com>2012-01-09 00:37:31 +0100
commit65349d60d27e850c94544567c91ab1be3e4c0777 (patch)
tree94344d80022bd870caa8ceab73df5a51c954a5dc /drivers/mfd/twl4030-audio.c
parent35ca98423a4c61decc20cd1d1e78a7fd7111e4db (diff)
downloadlinux-stable-65349d60d27e850c94544567c91ab1be3e4c0777.tar.gz
linux-stable-65349d60d27e850c94544567c91ab1be3e4c0777.tar.bz2
linux-stable-65349d60d27e850c94544567c91ab1be3e4c0777.zip
mfd: Convert MFD drivers to use module_platform_driver
Factors out some boilerplate code for drivers doing the default thing for platform driver registration. Drivers using platform_driver_probe or an initcall other than module_init can't be converted. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/mfd/twl4030-audio.c')
-rw-r--r--drivers/mfd/twl4030-audio.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/mfd/twl4030-audio.c b/drivers/mfd/twl4030-audio.c
index ae51ab5d0e5d..838ce4eb444e 100644
--- a/drivers/mfd/twl4030-audio.c
+++ b/drivers/mfd/twl4030-audio.c
@@ -261,17 +261,7 @@ static struct platform_driver twl4030_audio_driver = {
},
};
-static int __devinit twl4030_audio_init(void)
-{
- return platform_driver_register(&twl4030_audio_driver);
-}
-module_init(twl4030_audio_init);
-
-static void __devexit twl4030_audio_exit(void)
-{
- platform_driver_unregister(&twl4030_audio_driver);
-}
-module_exit(twl4030_audio_exit);
+module_platform_driver(twl4030_audio_driver);
MODULE_AUTHOR("Peter Ujfalusi <peter.ujfalusi@ti.com>");
MODULE_LICENSE("GPL");