aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@gmail.com>2012-01-10 18:09:24 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2012-01-10 19:30:48 -0500
commit892a8843fbef07a7f2ab62d5f7ff5c16ea0903b0 (patch)
treecddc55a75280ec2851e26f127acd2f05e9483cc1
parente2c17bc6f717a8847df2a867caec6ba4fe85f3fc (diff)
leds: convert led platform drivers to module_platform_driver
Factor out some boilerplate code for platform driver registration into module_platform_driver. Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Haojian Zhuang <hzhuang1@marvell.com> [led-88pm860x.c] Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: Richard Purdie <rpurdie@rpsys.net> Cc: Michael Hennerich <hennerich@blackfin.uclinux.org> Cc: Mike Rapoport <mike@compulab.co.il> Cc: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--drivers/leds/leds-88pm860x.c12
-rw-r--r--drivers/leds/leds-adp5520.c12
-rw-r--r--drivers/leds/leds-ams-delta.c13
-rw-r--r--drivers/leds/leds-asic3.c16
-rw-r--r--drivers/leds/leds-atmel-pwm.c17
-rw-r--r--drivers/leds/leds-cobalt-qube.c17
-rw-r--r--drivers/leds/leds-da903x.c12
-rw-r--r--drivers/leds/leds-fsg.c15
-rw-r--r--drivers/leds/leds-gpio.c16
-rw-r--r--drivers/leds/leds-hp6xx.c17
-rw-r--r--drivers/leds/leds-lt3593.c16
-rw-r--r--drivers/leds/leds-mc13783.c12
-rw-r--r--drivers/leds/leds-netxbig.c15
-rw-r--r--drivers/leds/leds-ns2.c15
-rw-r--r--drivers/leds/leds-pwm.c13
-rw-r--r--drivers/leds/leds-rb532.c16
-rw-r--r--drivers/leds/leds-regulator.c12
-rw-r--r--drivers/leds/leds-renesas-tpu.c13
-rw-r--r--drivers/leds/leds-s3c24xx.c13
-rw-r--r--drivers/leds/leds-wm831x-status.c12
-rw-r--r--drivers/leds/leds-wm8350.c12
21 files changed, 31 insertions, 265 deletions
diff --git a/drivers/leds/leds-88pm860x.c b/drivers/leds/leds-88pm860x.c
index 0810604dc701..4ca00624bd18 100644
--- a/drivers/leds/leds-88pm860x.c
+++ b/drivers/leds/leds-88pm860x.c
@@ -238,17 +238,7 @@ static struct platform_driver pm860x_led_driver = {
238 .remove = pm860x_led_remove, 238 .remove = pm860x_led_remove,
239}; 239};
240 240
241static int __devinit pm860x_led_init(void) 241module_platform_driver(pm860x_led_driver);
242{
243 return platform_driver_register(&pm860x_led_driver);
244}
245module_init(pm860x_led_init);
246
247static void __devexit pm860x_led_exit(void)
248{
249 platform_driver_unregister(&pm860x_led_driver);
250}
251module_exit(pm860x_led_exit);
252 242
253MODULE_DESCRIPTION("LED driver for Marvell PM860x"); 243MODULE_DESCRIPTION("LED driver for Marvell PM860x");
254MODULE_AUTHOR("Haojian Zhuang <haojian.zhuang@marvell.com>"); 244MODULE_AUTHOR("Haojian Zhuang <haojian.zhuang@marvell.com>");
diff --git a/drivers/leds/leds-adp5520.c b/drivers/leds/leds-adp5520.c
index 7ba4c7b5b97e..b1400db3f839 100644
--- a/drivers/leds/leds-adp5520.c
+++ b/drivers/leds/leds-adp5520.c
@@ -213,17 +213,7 @@ static struct platform_driver adp5520_led_driver = {
213 .remove = __devexit_p(adp5520_led_remove), 213 .remove = __devexit_p(adp5520_led_remove),
214}; 214};
215 215
216static int __init adp5520_led_init(void) 216module_platform_driver(adp5520_led_driver);
217{
218 return platform_driver_register(&adp5520_led_driver);
219}
220module_init(adp5520_led_init);
221
222static void __exit adp5520_led_exit(void)
223{
224 platform_driver_unregister(&adp5520_led_driver);
225}
226module_exit(adp5520_led_exit);
227 217
228MODULE_AUTHOR("Michael Hennerich <hennerich@blackfin.uclinux.org>"); 218MODULE_AUTHOR("Michael Hennerich <hennerich@blackfin.uclinux.org>");
229MODULE_DESCRIPTION("LEDS ADP5520(01) Driver"); 219MODULE_DESCRIPTION("LEDS ADP5520(01) Driver");
diff --git a/drivers/leds/leds-ams-delta.c b/drivers/leds/leds-ams-delta.c
index 8c00937bf7e7..07428357c83f 100644
--- a/drivers/leds/leds-ams-delta.c
+++ b/drivers/leds/leds-ams-delta.c
@@ -118,18 +118,7 @@ static struct platform_driver ams_delta_led_driver = {
118 }, 118 },
119}; 119};
120 120
121static int __init ams_delta_led_init(void) 121module_platform_driver(ams_delta_led_driver);
122{
123 return platform_driver_register(&ams_delta_led_driver);
124}
125
126static void __exit ams_delta_led_exit(void)
127{
128 platform_driver_unregister(&ams_delta_led_driver);
129}
130
131module_init(ams_delta_led_init);
132module_exit(ams_delta_led_exit);
133 122
134MODULE_AUTHOR("Jonathan McDowell <noodles@earth.li>"); 123MODULE_AUTHOR("Jonathan McDowell <noodles@earth.li>");
135MODULE_DESCRIPTION("Amstrad Delta LED driver"); 124MODULE_DESCRIPTION("Amstrad Delta LED driver");
diff --git a/drivers/leds/leds-asic3.c b/drivers/leds/leds-asic3.c
index 48d9fe61bdfc..525a92492837 100644
--- a/drivers/leds/leds-asic3.c
+++ b/drivers/leds/leds-asic3.c
@@ -179,21 +179,9 @@ static struct platform_driver asic3_led_driver = {
179 }, 179 },
180}; 180};
181 181
182MODULE_ALIAS("platform:leds-asic3"); 182module_platform_driver(asic3_led_driver);
183
184static int __init asic3_led_init(void)
185{
186 return platform_driver_register(&asic3_led_driver);
187}
188
189static void __exit asic3_led_exit(void)
190{
191 platform_driver_unregister(&asic3_led_driver);
192}
193
194module_init(asic3_led_init);
195module_exit(asic3_led_exit);
196 183
197MODULE_AUTHOR("Paul Parsons <lost.distance@yahoo.com>"); 184MODULE_AUTHOR("Paul Parsons <lost.distance@yahoo.com>");
198MODULE_DESCRIPTION("HTC ASIC3 LED driver"); 185MODULE_DESCRIPTION("HTC ASIC3 LED driver");
199MODULE_LICENSE("GPL"); 186MODULE_LICENSE("GPL");
187MODULE_ALIAS("platform:leds-asic3");
diff --git a/drivers/leds/leds-atmel-pwm.c b/drivers/leds/leds-atmel-pwm.c
index 109c875ea233..800243b6037e 100644
--- a/drivers/leds/leds-atmel-pwm.c
+++ b/drivers/leds/leds-atmel-pwm.c
@@ -134,29 +134,18 @@ static int __exit pwmled_remove(struct platform_device *pdev)
134 return 0; 134 return 0;
135} 135}
136 136
137/* work with hotplug and coldplug */
138MODULE_ALIAS("platform:leds-atmel-pwm");
139
140static struct platform_driver pwmled_driver = { 137static struct platform_driver pwmled_driver = {
141 .driver = { 138 .driver = {
142 .name = "leds-atmel-pwm", 139 .name = "leds-atmel-pwm",
143 .owner = THIS_MODULE, 140 .owner = THIS_MODULE,
144 }, 141 },
145 /* REVISIT add suspend() and resume() methods */ 142 /* REVISIT add suspend() and resume() methods */
143 .probe = pwmled_probe,
146 .remove = __exit_p(pwmled_remove), 144 .remove = __exit_p(pwmled_remove),
147}; 145};
148 146
149static int __init modinit(void) 147module_platform_driver(pwmled_driver);
150{
151 return platform_driver_probe(&pwmled_driver, pwmled_probe);
152}
153module_init(modinit);
154
155static void __exit modexit(void)
156{
157 platform_driver_unregister(&pwmled_driver);
158}
159module_exit(modexit);
160 148
161MODULE_DESCRIPTION("Driver for LEDs with PWM-controlled brightness"); 149MODULE_DESCRIPTION("Driver for LEDs with PWM-controlled brightness");
162MODULE_LICENSE("GPL"); 150MODULE_LICENSE("GPL");
151MODULE_ALIAS("platform:leds-atmel-pwm");
diff --git a/drivers/leds/leds-cobalt-qube.c b/drivers/leds/leds-cobalt-qube.c
index da5fb016b1a5..6a8725cc7b4d 100644
--- a/drivers/leds/leds-cobalt-qube.c
+++ b/drivers/leds/leds-cobalt-qube.c
@@ -75,9 +75,6 @@ static int __devexit cobalt_qube_led_remove(struct platform_device *pdev)
75 return 0; 75 return 0;
76} 76}
77 77
78/* work with hotplug and coldplug */
79MODULE_ALIAS("platform:cobalt-qube-leds");
80
81static struct platform_driver cobalt_qube_led_driver = { 78static struct platform_driver cobalt_qube_led_driver = {
82 .probe = cobalt_qube_led_probe, 79 .probe = cobalt_qube_led_probe,
83 .remove = __devexit_p(cobalt_qube_led_remove), 80 .remove = __devexit_p(cobalt_qube_led_remove),
@@ -87,19 +84,9 @@ static struct platform_driver cobalt_qube_led_driver = {
87 }, 84 },
88}; 85};
89 86
90static int __init cobalt_qube_led_init(void) 87module_platform_driver(cobalt_qube_led_driver);
91{
92 return platform_driver_register(&cobalt_qube_led_driver);
93}
94
95static void __exit cobalt_qube_led_exit(void)
96{
97 platform_driver_unregister(&cobalt_qube_led_driver);
98}
99
100module_init(cobalt_qube_led_init);
101module_exit(cobalt_qube_led_exit);
102 88
103MODULE_LICENSE("GPL"); 89MODULE_LICENSE("GPL");
104MODULE_DESCRIPTION("Front LED support for Cobalt Server"); 90MODULE_DESCRIPTION("Front LED support for Cobalt Server");
105MODULE_AUTHOR("Florian Fainelli <florian@openwrt.org>"); 91MODULE_AUTHOR("Florian Fainelli <florian@openwrt.org>");
92MODULE_ALIAS("platform:cobalt-qube-leds");
diff --git a/drivers/leds/leds-da903x.c b/drivers/leds/leds-da903x.c
index f28931cf6781..d9cd73ebd6c4 100644
--- a/drivers/leds/leds-da903x.c
+++ b/drivers/leds/leds-da903x.c
@@ -158,17 +158,7 @@ static struct platform_driver da903x_led_driver = {
158 .remove = __devexit_p(da903x_led_remove), 158 .remove = __devexit_p(da903x_led_remove),
159}; 159};
160 160
161static int __init da903x_led_init(void) 161module_platform_driver(da903x_led_driver);
162{
163 return platform_driver_register(&da903x_led_driver);
164}
165module_init(da903x_led_init);
166
167static void __exit da903x_led_exit(void)
168{
169 platform_driver_unregister(&da903x_led_driver);
170}
171module_exit(da903x_led_exit);
172 162
173MODULE_DESCRIPTION("LEDs driver for Dialog Semiconductor DA9030/DA9034"); 163MODULE_DESCRIPTION("LEDs driver for Dialog Semiconductor DA9030/DA9034");
174MODULE_AUTHOR("Eric Miao <eric.miao@marvell.com>" 164MODULE_AUTHOR("Eric Miao <eric.miao@marvell.com>"
diff --git a/drivers/leds/leds-fsg.c b/drivers/leds/leds-fsg.c
index 49aceffaa5b6..b9053fa6e253 100644
--- a/drivers/leds/leds-fsg.c
+++ b/drivers/leds/leds-fsg.c
@@ -224,20 +224,7 @@ static struct platform_driver fsg_led_driver = {
224 }, 224 },
225}; 225};
226 226
227 227module_platform_driver(fsg_led_driver);
228static int __init fsg_led_init(void)
229{
230 return platform_driver_register(&fsg_led_driver);
231}
232
233static void __exit fsg_led_exit(void)
234{
235 platform_driver_unregister(&fsg_led_driver);
236}
237
238
239module_init(fsg_led_init);
240module_exit(fsg_led_exit);
241 228
242MODULE_AUTHOR("Rod Whitby <rod@whitby.id.au>"); 229MODULE_AUTHOR("Rod Whitby <rod@whitby.id.au>");
243MODULE_DESCRIPTION("Freecom FSG-3 LED driver"); 230MODULE_DESCRIPTION("Freecom FSG-3 LED driver");
diff --git a/drivers/leds/leds-gpio.c b/drivers/leds/leds-gpio.c
index 399a86f2013a..7df74cb97e70 100644
--- a/drivers/leds/leds-gpio.c
+++ b/drivers/leds/leds-gpio.c
@@ -293,21 +293,9 @@ static struct platform_driver gpio_led_driver = {
293 }, 293 },
294}; 294};
295 295
296MODULE_ALIAS("platform:leds-gpio"); 296module_platform_driver(gpio_led_driver);
297
298static int __init gpio_led_init(void)
299{
300 return platform_driver_register(&gpio_led_driver);
301}
302
303static void __exit gpio_led_exit(void)
304{
305 platform_driver_unregister(&gpio_led_driver);
306}
307
308module_init(gpio_led_init);
309module_exit(gpio_led_exit);
310 297
311MODULE_AUTHOR("Raphael Assenat <raph@8d.com>, Trent Piepho <tpiepho@freescale.com>"); 298MODULE_AUTHOR("Raphael Assenat <raph@8d.com>, Trent Piepho <tpiepho@freescale.com>");
312MODULE_DESCRIPTION("GPIO LED driver"); 299MODULE_DESCRIPTION("GPIO LED driver");
313MODULE_LICENSE("GPL"); 300MODULE_LICENSE("GPL");
301MODULE_ALIAS("platform:leds-gpio");
diff --git a/drivers/leds/leds-hp6xx.c b/drivers/leds/leds-hp6xx.c
index bcfbd3a60eab..366b6055e330 100644
--- a/drivers/leds/leds-hp6xx.c
+++ b/drivers/leds/leds-hp6xx.c
@@ -79,9 +79,6 @@ static int hp6xxled_remove(struct platform_device *pdev)
79 return 0; 79 return 0;
80} 80}
81 81
82/* work with hotplug and coldplug */
83MODULE_ALIAS("platform:hp6xx-led");
84
85static struct platform_driver hp6xxled_driver = { 82static struct platform_driver hp6xxled_driver = {
86 .probe = hp6xxled_probe, 83 .probe = hp6xxled_probe,
87 .remove = hp6xxled_remove, 84 .remove = hp6xxled_remove,
@@ -91,19 +88,9 @@ static struct platform_driver hp6xxled_driver = {
91 }, 88 },
92}; 89};
93 90
94static int __init hp6xxled_init(void) 91module_platform_driver(hp6xxled_driver);
95{
96 return platform_driver_register(&hp6xxled_driver);
97}
98
99static void __exit hp6xxled_exit(void)
100{
101 platform_driver_unregister(&hp6xxled_driver);
102}
103
104module_init(hp6xxled_init);
105module_exit(hp6xxled_exit);
106 92
107MODULE_AUTHOR("Kristoffer Ericson <kristoffer.ericson@gmail.com>"); 93MODULE_AUTHOR("Kristoffer Ericson <kristoffer.ericson@gmail.com>");
108MODULE_DESCRIPTION("HP Jornada 6xx LED driver"); 94MODULE_DESCRIPTION("HP Jornada 6xx LED driver");
109MODULE_LICENSE("GPL"); 95MODULE_LICENSE("GPL");
96MODULE_ALIAS("platform:hp6xx-led");
diff --git a/drivers/leds/leds-lt3593.c b/drivers/leds/leds-lt3593.c
index 53f67b8ce55d..e311a96c4469 100644
--- a/drivers/leds/leds-lt3593.c
+++ b/drivers/leds/leds-lt3593.c
@@ -199,21 +199,9 @@ static struct platform_driver lt3593_led_driver = {
199 }, 199 },
200}; 200};
201 201
202MODULE_ALIAS("platform:leds-lt3593"); 202module_platform_driver(lt3593_led_driver);
203
204static int __init lt3593_led_init(void)
205{
206 return platform_driver_register(&lt3593_led_driver);
207}
208
209static void __exit lt3593_led_exit(void)
210{
211 platform_driver_unregister(&lt3593_led_driver);
212}
213
214module_init(lt3593_led_init);
215module_exit(lt3593_led_exit);
216 203
217MODULE_AUTHOR("Daniel Mack <daniel@caiaq.de>"); 204MODULE_AUTHOR("Daniel Mack <daniel@caiaq.de>");
218MODULE_DESCRIPTION("LED driver for LT3593 controllers"); 205MODULE_DESCRIPTION("LED driver for LT3593 controllers");
219MODULE_LICENSE("GPL"); 206MODULE_LICENSE("GPL");
207MODULE_ALIAS("platform:leds-lt3593");
diff --git a/drivers/leds/leds-mc13783.c b/drivers/leds/leds-mc13783.c
index b3393a9f2139..c61e8c4f5469 100644
--- a/drivers/leds/leds-mc13783.c
+++ b/drivers/leds/leds-mc13783.c
@@ -385,17 +385,7 @@ static struct platform_driver mc13783_led_driver = {
385 .remove = __devexit_p(mc13783_led_remove), 385 .remove = __devexit_p(mc13783_led_remove),
386}; 386};
387 387
388static int __init mc13783_led_init(void) 388module_platform_driver(mc13783_led_driver);
389{
390 return platform_driver_register(&mc13783_led_driver);
391}
392module_init(mc13783_led_init);
393
394static void __exit mc13783_led_exit(void)
395{
396 platform_driver_unregister(&mc13783_led_driver);
397}
398module_exit(mc13783_led_exit);
399 389
400MODULE_DESCRIPTION("LEDs driver for Freescale MC13783 PMIC"); 390MODULE_DESCRIPTION("LEDs driver for Freescale MC13783 PMIC");
401MODULE_AUTHOR("Philippe Retornaz <philippe.retornaz@epfl.ch>"); 391MODULE_AUTHOR("Philippe Retornaz <philippe.retornaz@epfl.ch>");
diff --git a/drivers/leds/leds-netxbig.c b/drivers/leds/leds-netxbig.c
index f2e51c134399..8c7a4ea10dc3 100644
--- a/drivers/leds/leds-netxbig.c
+++ b/drivers/leds/leds-netxbig.c
@@ -429,21 +429,10 @@ static struct platform_driver netxbig_led_driver = {
429 .owner = THIS_MODULE, 429 .owner = THIS_MODULE,
430 }, 430 },
431}; 431};
432MODULE_ALIAS("platform:leds-netxbig");
433
434static int __init netxbig_led_init(void)
435{
436 return platform_driver_register(&netxbig_led_driver);
437}
438 432
439static void __exit netxbig_led_exit(void) 433module_platform_driver(netxbig_led_driver);
440{
441 platform_driver_unregister(&netxbig_led_driver);
442}
443
444module_init(netxbig_led_init);
445module_exit(netxbig_led_exit);
446 434
447MODULE_AUTHOR("Simon Guinot <sguinot@lacie.com>"); 435MODULE_AUTHOR("Simon Guinot <sguinot@lacie.com>");
448MODULE_DESCRIPTION("LED driver for LaCie xBig Network boards"); 436MODULE_DESCRIPTION("LED driver for LaCie xBig Network boards");
449MODULE_LICENSE("GPL"); 437MODULE_LICENSE("GPL");
438MODULE_ALIAS("platform:leds-netxbig");
diff --git a/drivers/leds/leds-ns2.c b/drivers/leds/leds-ns2.c
index 37b7d0cfe586..2f0a14421a73 100644
--- a/drivers/leds/leds-ns2.c
+++ b/drivers/leds/leds-ns2.c
@@ -323,21 +323,10 @@ static struct platform_driver ns2_led_driver = {
323 .owner = THIS_MODULE, 323 .owner = THIS_MODULE,
324 }, 324 },
325}; 325};
326MODULE_ALIAS("platform:leds-ns2");
327
328static int __init ns2_led_init(void)
329{
330 return platform_driver_register(&ns2_led_driver);
331}
332 326
333static void __exit ns2_led_exit(void) 327module_platform_driver(ns2_led_driver);
334{
335 platform_driver_unregister(&ns2_led_driver);
336}
337
338module_init(ns2_led_init);
339module_exit(ns2_led_exit);
340 328
341MODULE_AUTHOR("Simon Guinot <sguinot@lacie.com>"); 329MODULE_AUTHOR("Simon Guinot <sguinot@lacie.com>");
342MODULE_DESCRIPTION("Network Space v2 LED driver"); 330MODULE_DESCRIPTION("Network Space v2 LED driver");
343MODULE_LICENSE("GPL"); 331MODULE_LICENSE("GPL");
332MODULE_ALIAS("platform:leds-ns2");
diff --git a/drivers/leds/leds-pwm.c b/drivers/leds/leds-pwm.c
index 666daf77872e..3ed92f34bd44 100644
--- a/drivers/leds/leds-pwm.c
+++ b/drivers/leds/leds-pwm.c
@@ -135,18 +135,7 @@ static struct platform_driver led_pwm_driver = {
135 }, 135 },
136}; 136};
137 137
138static int __init led_pwm_init(void) 138module_platform_driver(led_pwm_driver);
139{
140 return platform_driver_register(&led_pwm_driver);
141}
142
143static void __exit led_pwm_exit(void)
144{
145 platform_driver_unregister(&led_pwm_driver);
146}
147
148module_init(led_pwm_init);
149module_exit(led_pwm_exit);
150 139
151MODULE_AUTHOR("Luotao Fu <l.fu@pengutronix.de>"); 140MODULE_AUTHOR("Luotao Fu <l.fu@pengutronix.de>");
152MODULE_DESCRIPTION("PWM LED driver for PXA"); 141MODULE_DESCRIPTION("PWM LED driver for PXA");
diff --git a/drivers/leds/leds-rb532.c b/drivers/leds/leds-rb532.c
index c3525f37f73d..a7815b6cd856 100644
--- a/drivers/leds/leds-rb532.c
+++ b/drivers/leds/leds-rb532.c
@@ -57,21 +57,9 @@ static struct platform_driver rb532_led_driver = {
57 }, 57 },
58}; 58};
59 59
60static int __init rb532_led_init(void) 60module_platform_driver(rb532_led_driver);
61{
62 return platform_driver_register(&rb532_led_driver);
63}
64
65static void __exit rb532_led_exit(void)
66{
67 platform_driver_unregister(&rb532_led_driver);
68}
69
70module_init(rb532_led_init);
71module_exit(rb532_led_exit);
72
73MODULE_ALIAS("platform:rb532-led");
74 61
75MODULE_LICENSE("GPL"); 62MODULE_LICENSE("GPL");
76MODULE_DESCRIPTION("User LED support for Routerboard532"); 63MODULE_DESCRIPTION("User LED support for Routerboard532");
77MODULE_AUTHOR("Phil Sutter <n0-1@freewrt.org>"); 64MODULE_AUTHOR("Phil Sutter <n0-1@freewrt.org>");
65MODULE_ALIAS("platform:rb532-led");
diff --git a/drivers/leds/leds-regulator.c b/drivers/leds/leds-regulator.c
index 8497f56f8e46..df7e963bddd3 100644
--- a/drivers/leds/leds-regulator.c
+++ b/drivers/leds/leds-regulator.c
@@ -229,17 +229,7 @@ static struct platform_driver regulator_led_driver = {
229 .remove = __devexit_p(regulator_led_remove), 229 .remove = __devexit_p(regulator_led_remove),
230}; 230};
231 231
232static int __init regulator_led_init(void) 232module_platform_driver(regulator_led_driver);
233{
234 return platform_driver_register(&regulator_led_driver);
235}
236module_init(regulator_led_init);
237
238static void __exit regulator_led_exit(void)
239{
240 platform_driver_unregister(&regulator_led_driver);
241}
242module_exit(regulator_led_exit);
243 233
244MODULE_AUTHOR("Antonio Ospite <ospite@studenti.unina.it>"); 234MODULE_AUTHOR("Antonio Ospite <ospite@studenti.unina.it>");
245MODULE_DESCRIPTION("Regulator driven LED driver"); 235MODULE_DESCRIPTION("Regulator driven LED driver");
diff --git a/drivers/leds/leds-renesas-tpu.c b/drivers/leds/leds-renesas-tpu.c
index 3ee540eb127e..32fe337d5c68 100644
--- a/drivers/leds/leds-renesas-tpu.c
+++ b/drivers/leds/leds-renesas-tpu.c
@@ -339,18 +339,7 @@ static struct platform_driver r_tpu_device_driver = {
339 } 339 }
340}; 340};
341 341
342static int __init r_tpu_init(void) 342module_platform_driver(r_tpu_device_driver);
343{
344 return platform_driver_register(&r_tpu_device_driver);
345}
346
347static void __exit r_tpu_exit(void)
348{
349 platform_driver_unregister(&r_tpu_device_driver);
350}
351
352module_init(r_tpu_init);
353module_exit(r_tpu_exit);
354 343
355MODULE_AUTHOR("Magnus Damm"); 344MODULE_AUTHOR("Magnus Damm");
356MODULE_DESCRIPTION("Renesas TPU LED Driver"); 345MODULE_DESCRIPTION("Renesas TPU LED Driver");
diff --git a/drivers/leds/leds-s3c24xx.c b/drivers/leds/leds-s3c24xx.c
index 29f8b0f0e2c6..bd0a5ed49c42 100644
--- a/drivers/leds/leds-s3c24xx.c
+++ b/drivers/leds/leds-s3c24xx.c
@@ -121,18 +121,7 @@ static struct platform_driver s3c24xx_led_driver = {
121 }, 121 },
122}; 122};
123 123
124static int __init s3c24xx_led_init(void) 124module_platform_driver(s3c24xx_led_driver);
125{
126 return platform_driver_register(&s3c24xx_led_driver);
127}
128
129static void __exit s3c24xx_led_exit(void)
130{
131 platform_driver_unregister(&s3c24xx_led_driver);
132}
133
134module_init(s3c24xx_led_init);
135module_exit(s3c24xx_led_exit);
136 125
137MODULE_AUTHOR("Ben Dooks <ben@simtec.co.uk>"); 126MODULE_AUTHOR("Ben Dooks <ben@simtec.co.uk>");
138MODULE_DESCRIPTION("S3C24XX LED driver"); 127MODULE_DESCRIPTION("S3C24XX LED driver");
diff --git a/drivers/leds/leds-wm831x-status.c b/drivers/leds/leds-wm831x-status.c
index b1eb34c3e81f..444a68d8e17e 100644
--- a/drivers/leds/leds-wm831x-status.c
+++ b/drivers/leds/leds-wm831x-status.c
@@ -325,17 +325,7 @@ static struct platform_driver wm831x_status_driver = {
325 .remove = wm831x_status_remove, 325 .remove = wm831x_status_remove,
326}; 326};
327 327
328static int __devinit wm831x_status_init(void) 328module_platform_driver(wm831x_status_driver);
329{
330 return platform_driver_register(&wm831x_status_driver);
331}
332module_init(wm831x_status_init);
333
334static void wm831x_status_exit(void)
335{
336 platform_driver_unregister(&wm831x_status_driver);
337}
338module_exit(wm831x_status_exit);
339 329
340MODULE_AUTHOR("Mark Brown <broonie@opensource.wolfsonmicro.com>"); 330MODULE_AUTHOR("Mark Brown <broonie@opensource.wolfsonmicro.com>");
341MODULE_DESCRIPTION("WM831x status LED driver"); 331MODULE_DESCRIPTION("WM831x status LED driver");
diff --git a/drivers/leds/leds-wm8350.c b/drivers/leds/leds-wm8350.c
index 4a1276578352..390c0f679628 100644
--- a/drivers/leds/leds-wm8350.c
+++ b/drivers/leds/leds-wm8350.c
@@ -295,17 +295,7 @@ static struct platform_driver wm8350_led_driver = {
295 .shutdown = wm8350_led_shutdown, 295 .shutdown = wm8350_led_shutdown,
296}; 296};
297 297
298static int __devinit wm8350_led_init(void) 298module_platform_driver(wm8350_led_driver);
299{
300 return platform_driver_register(&wm8350_led_driver);
301}
302module_init(wm8350_led_init);
303
304static void wm8350_led_exit(void)
305{
306 platform_driver_unregister(&wm8350_led_driver);
307}
308module_exit(wm8350_led_exit);
309 299
310MODULE_AUTHOR("Mark Brown"); 300MODULE_AUTHOR("Mark Brown");
311MODULE_DESCRIPTION("WM8350 LED driver"); 301MODULE_DESCRIPTION("WM8350 LED driver");