diff options
author | Axel Lin <axel.lin@gmail.com> | 2011-11-24 21:06:59 -0500 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-11-25 08:15:16 -0500 |
commit | 8a124f9cc9bafc40f5650e63a84ba1ff98a36ea0 (patch) | |
tree | 1698eade3f3682741fad3df339147a30bc568645 /sound/soc/au1x | |
parent | b31c9056e400ddf10ec9691c6fada2fba1709330 (diff) |
ASoC: Convert au1x directory to module_platform_driver
Factor out some boilerplate code.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/au1x')
-rw-r--r-- | sound/soc/au1x/db1000.c | 13 | ||||
-rw-r--r-- | sound/soc/au1x/db1200.c | 13 | ||||
-rw-r--r-- | sound/soc/au1x/dbdma2.c | 13 | ||||
-rw-r--r-- | sound/soc/au1x/dma.c | 13 | ||||
-rw-r--r-- | sound/soc/au1x/i2sc.c | 13 | ||||
-rw-r--r-- | sound/soc/au1x/psc-i2s.c | 13 |
6 files changed, 6 insertions, 72 deletions
diff --git a/sound/soc/au1x/db1000.c b/sound/soc/au1x/db1000.c index 127477a5e0c..094a20723bc 100644 --- a/sound/soc/au1x/db1000.c +++ b/sound/soc/au1x/db1000.c | |||
@@ -57,18 +57,7 @@ static struct platform_driver db1000_audio_driver = { | |||
57 | .remove = __devexit_p(db1000_audio_remove), | 57 | .remove = __devexit_p(db1000_audio_remove), |
58 | }; | 58 | }; |
59 | 59 | ||
60 | static int __init db1000_audio_load(void) | 60 | module_platform_driver(db1000_audio_driver); |
61 | { | ||
62 | return platform_driver_register(&db1000_audio_driver); | ||
63 | } | ||
64 | |||
65 | static void __exit db1000_audio_unload(void) | ||
66 | { | ||
67 | platform_driver_unregister(&db1000_audio_driver); | ||
68 | } | ||
69 | |||
70 | module_init(db1000_audio_load); | ||
71 | module_exit(db1000_audio_unload); | ||
72 | 61 | ||
73 | MODULE_LICENSE("GPL"); | 62 | MODULE_LICENSE("GPL"); |
74 | MODULE_DESCRIPTION("DB1000/DB1500/DB1100 ASoC audio"); | 63 | MODULE_DESCRIPTION("DB1000/DB1500/DB1100 ASoC audio"); |
diff --git a/sound/soc/au1x/db1200.c b/sound/soc/au1x/db1200.c index 289312c14b9..80733331733 100644 --- a/sound/soc/au1x/db1200.c +++ b/sound/soc/au1x/db1200.c | |||
@@ -133,18 +133,7 @@ static struct platform_driver db1200_audio_driver = { | |||
133 | .remove = __devexit_p(db1200_audio_remove), | 133 | .remove = __devexit_p(db1200_audio_remove), |
134 | }; | 134 | }; |
135 | 135 | ||
136 | static int __init db1200_audio_load(void) | 136 | module_platform_driver(db1200_audio_driver); |
137 | { | ||
138 | return platform_driver_register(&db1200_audio_driver); | ||
139 | } | ||
140 | |||
141 | static void __exit db1200_audio_unload(void) | ||
142 | { | ||
143 | platform_driver_unregister(&db1200_audio_driver); | ||
144 | } | ||
145 | |||
146 | module_init(db1200_audio_load); | ||
147 | module_exit(db1200_audio_unload); | ||
148 | 137 | ||
149 | MODULE_LICENSE("GPL"); | 138 | MODULE_LICENSE("GPL"); |
150 | MODULE_DESCRIPTION("DB1200 ASoC audio support"); | 139 | MODULE_DESCRIPTION("DB1200 ASoC audio support"); |
diff --git a/sound/soc/au1x/dbdma2.c b/sound/soc/au1x/dbdma2.c index d7d04e26eee..09699de9b33 100644 --- a/sound/soc/au1x/dbdma2.c +++ b/sound/soc/au1x/dbdma2.c | |||
@@ -384,18 +384,7 @@ static struct platform_driver au1xpsc_pcm_driver = { | |||
384 | .remove = __devexit_p(au1xpsc_pcm_drvremove), | 384 | .remove = __devexit_p(au1xpsc_pcm_drvremove), |
385 | }; | 385 | }; |
386 | 386 | ||
387 | static int __init au1xpsc_audio_dbdma_load(void) | 387 | module_platform_driver(au1xpsc_pcm_driver); |
388 | { | ||
389 | return platform_driver_register(&au1xpsc_pcm_driver); | ||
390 | } | ||
391 | |||
392 | static void __exit au1xpsc_audio_dbdma_unload(void) | ||
393 | { | ||
394 | platform_driver_unregister(&au1xpsc_pcm_driver); | ||
395 | } | ||
396 | |||
397 | module_init(au1xpsc_audio_dbdma_load); | ||
398 | module_exit(au1xpsc_audio_dbdma_unload); | ||
399 | 388 | ||
400 | MODULE_LICENSE("GPL"); | 389 | MODULE_LICENSE("GPL"); |
401 | MODULE_DESCRIPTION("Au12x0/Au1550 PSC Audio DMA driver"); | 390 | MODULE_DESCRIPTION("Au12x0/Au1550 PSC Audio DMA driver"); |
diff --git a/sound/soc/au1x/dma.c b/sound/soc/au1x/dma.c index 177f7137a9c..dc4dae48aed 100644 --- a/sound/soc/au1x/dma.c +++ b/sound/soc/au1x/dma.c | |||
@@ -359,18 +359,7 @@ static struct platform_driver alchemy_pcmdma_driver = { | |||
359 | .remove = __devexit_p(alchemy_pcm_drvremove), | 359 | .remove = __devexit_p(alchemy_pcm_drvremove), |
360 | }; | 360 | }; |
361 | 361 | ||
362 | static int __init alchemy_pcmdma_load(void) | 362 | module_platform_driver(alchemy_pcmdma_driver); |
363 | { | ||
364 | return platform_driver_register(&alchemy_pcmdma_driver); | ||
365 | } | ||
366 | |||
367 | static void __exit alchemy_pcmdma_unload(void) | ||
368 | { | ||
369 | platform_driver_unregister(&alchemy_pcmdma_driver); | ||
370 | } | ||
371 | |||
372 | module_init(alchemy_pcmdma_load); | ||
373 | module_exit(alchemy_pcmdma_unload); | ||
374 | 363 | ||
375 | MODULE_LICENSE("GPL"); | 364 | MODULE_LICENSE("GPL"); |
376 | MODULE_DESCRIPTION("Au1000/Au1500/Au1100 Audio DMA driver"); | 365 | MODULE_DESCRIPTION("Au1000/Au1500/Au1100 Audio DMA driver"); |
diff --git a/sound/soc/au1x/i2sc.c b/sound/soc/au1x/i2sc.c index 6bcf48f5884..cb53ad87d0a 100644 --- a/sound/soc/au1x/i2sc.c +++ b/sound/soc/au1x/i2sc.c | |||
@@ -331,18 +331,7 @@ static struct platform_driver au1xi2s_driver = { | |||
331 | .remove = __devexit_p(au1xi2s_drvremove), | 331 | .remove = __devexit_p(au1xi2s_drvremove), |
332 | }; | 332 | }; |
333 | 333 | ||
334 | static int __init au1xi2s_load(void) | 334 | module_platform_driver(au1xi2s_driver); |
335 | { | ||
336 | return platform_driver_register(&au1xi2s_driver); | ||
337 | } | ||
338 | |||
339 | static void __exit au1xi2s_unload(void) | ||
340 | { | ||
341 | platform_driver_unregister(&au1xi2s_driver); | ||
342 | } | ||
343 | |||
344 | module_init(au1xi2s_load); | ||
345 | module_exit(au1xi2s_unload); | ||
346 | 335 | ||
347 | MODULE_LICENSE("GPL"); | 336 | MODULE_LICENSE("GPL"); |
348 | MODULE_DESCRIPTION("Au1000/1500/1100 I2S ASoC driver"); | 337 | MODULE_DESCRIPTION("Au1000/1500/1100 I2S ASoC driver"); |
diff --git a/sound/soc/au1x/psc-i2s.c b/sound/soc/au1x/psc-i2s.c index f7714d50bda..5c1dc8a141a 100644 --- a/sound/soc/au1x/psc-i2s.c +++ b/sound/soc/au1x/psc-i2s.c | |||
@@ -435,18 +435,7 @@ static struct platform_driver au1xpsc_i2s_driver = { | |||
435 | .remove = __devexit_p(au1xpsc_i2s_drvremove), | 435 | .remove = __devexit_p(au1xpsc_i2s_drvremove), |
436 | }; | 436 | }; |
437 | 437 | ||
438 | static int __init au1xpsc_i2s_load(void) | 438 | module_platform_driver(au1xpsc_i2s_driver); |
439 | { | ||
440 | return platform_driver_register(&au1xpsc_i2s_driver); | ||
441 | } | ||
442 | |||
443 | static void __exit au1xpsc_i2s_unload(void) | ||
444 | { | ||
445 | platform_driver_unregister(&au1xpsc_i2s_driver); | ||
446 | } | ||
447 | |||
448 | module_init(au1xpsc_i2s_load); | ||
449 | module_exit(au1xpsc_i2s_unload); | ||
450 | 439 | ||
451 | MODULE_LICENSE("GPL"); | 440 | MODULE_LICENSE("GPL"); |
452 | MODULE_DESCRIPTION("Au12x0/Au1550 PSC I2S ALSA ASoC audio driver"); | 441 | MODULE_DESCRIPTION("Au12x0/Au1550 PSC I2S ALSA ASoC audio driver"); |