aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@gmail.com>2012-03-23 18:02:31 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2012-03-23 19:58:39 -0400
commit0abc920116303e81702a38429a1b61a896e02b37 (patch)
tree69494f8249d1d55fac8a58ff2f67fc346ef52c16
parent109e941843893cb1b4f7bed24c615ba84ce00ff5 (diff)
rtc: convert rtc i2c drivers to module_i2c_driver
Factor out some boilerplate code for i2c driver registration into module_i2c_driver. Signed-off-by: Axel Lin <axel.lin@gmail.com> Cc: Piotr Ziecik <kosmo@semihalf.com> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: Scott Wood <scottwood@freescale.com> Cc: Srikanth Srinivasan <srikanth.srinivasan@freescale.com> Cc: Mike Rapoport <mike@compulab.co.il> Cc: Sergey Lapin <slapin@ossfans.org> Cc: Roman Fietze <roman.fietze@telemotive.de> Cc: Herbert Valerio Riedel <hvr@gnu.org> Cc: Alexander Bigga <ab@mycable.de> Cc: Dale Farnsworth <dale@farnsworth.org> Cc: Gregory Hermant <gregory.hermant@calao-systems.com> Cc: Wolfgang Grandegger <wg@grandegger.com> Cc: Martyn Welch <martyn.welch@ge.com> Cc: Byron Bradley <byron.bbradley@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--drivers/rtc/rtc-bq32k.c12
-rw-r--r--drivers/rtc/rtc-ds1307.c12
-rw-r--r--drivers/rtc/rtc-ds1374.c13
-rw-r--r--drivers/rtc/rtc-ds1672.c13
-rw-r--r--drivers/rtc/rtc-ds3232.c13
-rw-r--r--drivers/rtc/rtc-em3027.c13
-rw-r--r--drivers/rtc/rtc-fm3130.c12
-rw-r--r--drivers/rtc/rtc-isl12022.c13
-rw-r--r--drivers/rtc/rtc-isl1208.c15
-rw-r--r--drivers/rtc/rtc-m41t80.c13
-rw-r--r--drivers/rtc/rtc-max6900.c13
-rw-r--r--drivers/rtc/rtc-pcf8563.c13
-rw-r--r--drivers/rtc/rtc-pcf8583.c13
-rw-r--r--drivers/rtc/rtc-rs5c372.c13
-rw-r--r--drivers/rtc/rtc-rv3029c2.c13
-rw-r--r--drivers/rtc/rtc-rx8025.c13
-rw-r--r--drivers/rtc/rtc-rx8581.c13
-rw-r--r--drivers/rtc/rtc-s35390a.c13
-rw-r--r--drivers/rtc/rtc-x1205.c13
19 files changed, 19 insertions, 227 deletions
diff --git a/drivers/rtc/rtc-bq32k.c b/drivers/rtc/rtc-bq32k.c
index 408cc8f735be..f090159dce4a 100644
--- a/drivers/rtc/rtc-bq32k.c
+++ b/drivers/rtc/rtc-bq32k.c
@@ -187,17 +187,7 @@ static struct i2c_driver bq32k_driver = {
187 .id_table = bq32k_id, 187 .id_table = bq32k_id,
188}; 188};
189 189
190static __init int bq32k_init(void) 190module_i2c_driver(bq32k_driver);
191{
192 return i2c_add_driver(&bq32k_driver);
193}
194module_init(bq32k_init);
195
196static __exit void bq32k_exit(void)
197{
198 i2c_del_driver(&bq32k_driver);
199}
200module_exit(bq32k_exit);
201 191
202MODULE_AUTHOR("Semihalf, Piotr Ziecik <kosmo@semihalf.com>"); 192MODULE_AUTHOR("Semihalf, Piotr Ziecik <kosmo@semihalf.com>");
203MODULE_DESCRIPTION("TI BQ32000 I2C RTC driver"); 193MODULE_DESCRIPTION("TI BQ32000 I2C RTC driver");
diff --git a/drivers/rtc/rtc-ds1307.c b/drivers/rtc/rtc-ds1307.c
index 62b0763b7b9a..58edcb076742 100644
--- a/drivers/rtc/rtc-ds1307.c
+++ b/drivers/rtc/rtc-ds1307.c
@@ -938,17 +938,7 @@ static struct i2c_driver ds1307_driver = {
938 .id_table = ds1307_id, 938 .id_table = ds1307_id,
939}; 939};
940 940
941static int __init ds1307_init(void) 941module_i2c_driver(ds1307_driver);
942{
943 return i2c_add_driver(&ds1307_driver);
944}
945module_init(ds1307_init);
946
947static void __exit ds1307_exit(void)
948{
949 i2c_del_driver(&ds1307_driver);
950}
951module_exit(ds1307_exit);
952 942
953MODULE_DESCRIPTION("RTC driver for DS1307 and similar chips"); 943MODULE_DESCRIPTION("RTC driver for DS1307 and similar chips");
954MODULE_LICENSE("GPL"); 944MODULE_LICENSE("GPL");
diff --git a/drivers/rtc/rtc-ds1374.c b/drivers/rtc/rtc-ds1374.c
index e6e71deb188f..966316088b7f 100644
--- a/drivers/rtc/rtc-ds1374.c
+++ b/drivers/rtc/rtc-ds1374.c
@@ -446,18 +446,7 @@ static struct i2c_driver ds1374_driver = {
446 .id_table = ds1374_id, 446 .id_table = ds1374_id,
447}; 447};
448 448
449static int __init ds1374_init(void) 449module_i2c_driver(ds1374_driver);
450{
451 return i2c_add_driver(&ds1374_driver);
452}
453
454static void __exit ds1374_exit(void)
455{
456 i2c_del_driver(&ds1374_driver);
457}
458
459module_init(ds1374_init);
460module_exit(ds1374_exit);
461 450
462MODULE_AUTHOR("Scott Wood <scottwood@freescale.com>"); 451MODULE_AUTHOR("Scott Wood <scottwood@freescale.com>");
463MODULE_DESCRIPTION("Maxim/Dallas DS1374 RTC Driver"); 452MODULE_DESCRIPTION("Maxim/Dallas DS1374 RTC Driver");
diff --git a/drivers/rtc/rtc-ds1672.c b/drivers/rtc/rtc-ds1672.c
index a319402a5447..7fa67d0df172 100644
--- a/drivers/rtc/rtc-ds1672.c
+++ b/drivers/rtc/rtc-ds1672.c
@@ -202,20 +202,9 @@ static struct i2c_driver ds1672_driver = {
202 .id_table = ds1672_id, 202 .id_table = ds1672_id,
203}; 203};
204 204
205static int __init ds1672_init(void) 205module_i2c_driver(ds1672_driver);
206{
207 return i2c_add_driver(&ds1672_driver);
208}
209
210static void __exit ds1672_exit(void)
211{
212 i2c_del_driver(&ds1672_driver);
213}
214 206
215MODULE_AUTHOR("Alessandro Zummo <a.zummo@towertech.it>"); 207MODULE_AUTHOR("Alessandro Zummo <a.zummo@towertech.it>");
216MODULE_DESCRIPTION("Dallas/Maxim DS1672 timekeeper driver"); 208MODULE_DESCRIPTION("Dallas/Maxim DS1672 timekeeper driver");
217MODULE_LICENSE("GPL"); 209MODULE_LICENSE("GPL");
218MODULE_VERSION(DRV_VERSION); 210MODULE_VERSION(DRV_VERSION);
219
220module_init(ds1672_init);
221module_exit(ds1672_exit);
diff --git a/drivers/rtc/rtc-ds3232.c b/drivers/rtc/rtc-ds3232.c
index 27b7bf672ac6..e1945095814e 100644
--- a/drivers/rtc/rtc-ds3232.c
+++ b/drivers/rtc/rtc-ds3232.c
@@ -473,18 +473,7 @@ static struct i2c_driver ds3232_driver = {
473 .id_table = ds3232_id, 473 .id_table = ds3232_id,
474}; 474};
475 475
476static int __init ds3232_init(void) 476module_i2c_driver(ds3232_driver);
477{
478 return i2c_add_driver(&ds3232_driver);
479}
480
481static void __exit ds3232_exit(void)
482{
483 i2c_del_driver(&ds3232_driver);
484}
485
486module_init(ds3232_init);
487module_exit(ds3232_exit);
488 477
489MODULE_AUTHOR("Srikanth Srinivasan <srikanth.srinivasan@freescale.com>"); 478MODULE_AUTHOR("Srikanth Srinivasan <srikanth.srinivasan@freescale.com>");
490MODULE_DESCRIPTION("Maxim/Dallas DS3232 RTC Driver"); 479MODULE_DESCRIPTION("Maxim/Dallas DS3232 RTC Driver");
diff --git a/drivers/rtc/rtc-em3027.c b/drivers/rtc/rtc-em3027.c
index 8414dea5fb14..0104ea7ebe50 100644
--- a/drivers/rtc/rtc-em3027.c
+++ b/drivers/rtc/rtc-em3027.c
@@ -144,19 +144,8 @@ static struct i2c_driver em3027_driver = {
144 .id_table = em3027_id, 144 .id_table = em3027_id,
145}; 145};
146 146
147static int __init em3027_init(void) 147module_i2c_driver(em3027_driver);
148{
149 return i2c_add_driver(&em3027_driver);
150}
151
152static void __exit em3027_exit(void)
153{
154 i2c_del_driver(&em3027_driver);
155}
156 148
157MODULE_AUTHOR("Mike Rapoport <mike@compulab.co.il>"); 149MODULE_AUTHOR("Mike Rapoport <mike@compulab.co.il>");
158MODULE_DESCRIPTION("EM Microelectronic EM3027 RTC driver"); 150MODULE_DESCRIPTION("EM Microelectronic EM3027 RTC driver");
159MODULE_LICENSE("GPL"); 151MODULE_LICENSE("GPL");
160
161module_init(em3027_init);
162module_exit(em3027_exit);
diff --git a/drivers/rtc/rtc-fm3130.c b/drivers/rtc/rtc-fm3130.c
index 4cf2e70c5078..86b6ecce99f0 100644
--- a/drivers/rtc/rtc-fm3130.c
+++ b/drivers/rtc/rtc-fm3130.c
@@ -565,17 +565,7 @@ static struct i2c_driver fm3130_driver = {
565 .id_table = fm3130_id, 565 .id_table = fm3130_id,
566}; 566};
567 567
568static int __init fm3130_init(void) 568module_i2c_driver(fm3130_driver);
569{
570 return i2c_add_driver(&fm3130_driver);
571}
572module_init(fm3130_init);
573
574static void __exit fm3130_exit(void)
575{
576 i2c_del_driver(&fm3130_driver);
577}
578module_exit(fm3130_exit);
579 569
580MODULE_DESCRIPTION("RTC driver for FM3130"); 570MODULE_DESCRIPTION("RTC driver for FM3130");
581MODULE_AUTHOR("Sergey Lapin <slapin@ossfans.org>"); 571MODULE_AUTHOR("Sergey Lapin <slapin@ossfans.org>");
diff --git a/drivers/rtc/rtc-isl12022.c b/drivers/rtc/rtc-isl12022.c
index 6186833973ee..1850104705c0 100644
--- a/drivers/rtc/rtc-isl12022.c
+++ b/drivers/rtc/rtc-isl12022.c
@@ -309,18 +309,7 @@ static struct i2c_driver isl12022_driver = {
309 .id_table = isl12022_id, 309 .id_table = isl12022_id,
310}; 310};
311 311
312static int __init isl12022_init(void) 312module_i2c_driver(isl12022_driver);
313{
314 return i2c_add_driver(&isl12022_driver);
315}
316
317static void __exit isl12022_exit(void)
318{
319 i2c_del_driver(&isl12022_driver);
320}
321
322module_init(isl12022_init);
323module_exit(isl12022_exit);
324 313
325MODULE_AUTHOR("roman.fietze@telemotive.de"); 314MODULE_AUTHOR("roman.fietze@telemotive.de");
326MODULE_DESCRIPTION("ISL 12022 RTC driver"); 315MODULE_DESCRIPTION("ISL 12022 RTC driver");
diff --git a/drivers/rtc/rtc-isl1208.c b/drivers/rtc/rtc-isl1208.c
index da8beb8cae51..dd2aeee6c66a 100644
--- a/drivers/rtc/rtc-isl1208.c
+++ b/drivers/rtc/rtc-isl1208.c
@@ -710,22 +710,9 @@ static struct i2c_driver isl1208_driver = {
710 .id_table = isl1208_id, 710 .id_table = isl1208_id,
711}; 711};
712 712
713static int __init 713module_i2c_driver(isl1208_driver);
714isl1208_init(void)
715{
716 return i2c_add_driver(&isl1208_driver);
717}
718
719static void __exit
720isl1208_exit(void)
721{
722 i2c_del_driver(&isl1208_driver);
723}
724 714
725MODULE_AUTHOR("Herbert Valerio Riedel <hvr@gnu.org>"); 715MODULE_AUTHOR("Herbert Valerio Riedel <hvr@gnu.org>");
726MODULE_DESCRIPTION("Intersil ISL1208 RTC driver"); 716MODULE_DESCRIPTION("Intersil ISL1208 RTC driver");
727MODULE_LICENSE("GPL"); 717MODULE_LICENSE("GPL");
728MODULE_VERSION(DRV_VERSION); 718MODULE_VERSION(DRV_VERSION);
729
730module_init(isl1208_init);
731module_exit(isl1208_exit);
diff --git a/drivers/rtc/rtc-m41t80.c b/drivers/rtc/rtc-m41t80.c
index 64aedd8cc095..4e0f84af99a7 100644
--- a/drivers/rtc/rtc-m41t80.c
+++ b/drivers/rtc/rtc-m41t80.c
@@ -900,20 +900,9 @@ static struct i2c_driver m41t80_driver = {
900 .id_table = m41t80_id, 900 .id_table = m41t80_id,
901}; 901};
902 902
903static int __init m41t80_rtc_init(void) 903module_i2c_driver(m41t80_driver);
904{
905 return i2c_add_driver(&m41t80_driver);
906}
907
908static void __exit m41t80_rtc_exit(void)
909{
910 i2c_del_driver(&m41t80_driver);
911}
912 904
913MODULE_AUTHOR("Alexander Bigga <ab@mycable.de>"); 905MODULE_AUTHOR("Alexander Bigga <ab@mycable.de>");
914MODULE_DESCRIPTION("ST Microelectronics M41T80 series RTC I2C Client Driver"); 906MODULE_DESCRIPTION("ST Microelectronics M41T80 series RTC I2C Client Driver");
915MODULE_LICENSE("GPL"); 907MODULE_LICENSE("GPL");
916MODULE_VERSION(DRV_VERSION); 908MODULE_VERSION(DRV_VERSION);
917
918module_init(m41t80_rtc_init);
919module_exit(m41t80_rtc_exit);
diff --git a/drivers/rtc/rtc-max6900.c b/drivers/rtc/rtc-max6900.c
index 486142c2637a..a00e33204b91 100644
--- a/drivers/rtc/rtc-max6900.c
+++ b/drivers/rtc/rtc-max6900.c
@@ -261,20 +261,9 @@ static struct i2c_driver max6900_driver = {
261 .id_table = max6900_id, 261 .id_table = max6900_id,
262}; 262};
263 263
264static int __init max6900_init(void) 264module_i2c_driver(max6900_driver);
265{
266 return i2c_add_driver(&max6900_driver);
267}
268
269static void __exit max6900_exit(void)
270{
271 i2c_del_driver(&max6900_driver);
272}
273 265
274MODULE_DESCRIPTION("Maxim MAX6900 RTC driver"); 266MODULE_DESCRIPTION("Maxim MAX6900 RTC driver");
275MODULE_AUTHOR("Dale Farnsworth <dale@farnsworth.org>"); 267MODULE_AUTHOR("Dale Farnsworth <dale@farnsworth.org>");
276MODULE_LICENSE("GPL"); 268MODULE_LICENSE("GPL");
277MODULE_VERSION(DRV_VERSION); 269MODULE_VERSION(DRV_VERSION);
278
279module_init(max6900_init);
280module_exit(max6900_exit);
diff --git a/drivers/rtc/rtc-pcf8563.c b/drivers/rtc/rtc-pcf8563.c
index 606fdfab34e2..bc0677de1996 100644
--- a/drivers/rtc/rtc-pcf8563.c
+++ b/drivers/rtc/rtc-pcf8563.c
@@ -252,20 +252,9 @@ static struct i2c_driver pcf8563_driver = {
252 .id_table = pcf8563_id, 252 .id_table = pcf8563_id,
253}; 253};
254 254
255static int __init pcf8563_init(void) 255module_i2c_driver(pcf8563_driver);
256{
257 return i2c_add_driver(&pcf8563_driver);
258}
259
260static void __exit pcf8563_exit(void)
261{
262 i2c_del_driver(&pcf8563_driver);
263}
264 256
265MODULE_AUTHOR("Alessandro Zummo <a.zummo@towertech.it>"); 257MODULE_AUTHOR("Alessandro Zummo <a.zummo@towertech.it>");
266MODULE_DESCRIPTION("Philips PCF8563/Epson RTC8564 RTC driver"); 258MODULE_DESCRIPTION("Philips PCF8563/Epson RTC8564 RTC driver");
267MODULE_LICENSE("GPL"); 259MODULE_LICENSE("GPL");
268MODULE_VERSION(DRV_VERSION); 260MODULE_VERSION(DRV_VERSION);
269
270module_init(pcf8563_init);
271module_exit(pcf8563_exit);
diff --git a/drivers/rtc/rtc-pcf8583.c b/drivers/rtc/rtc-pcf8583.c
index 2d201afead3b..019ff3571168 100644
--- a/drivers/rtc/rtc-pcf8583.c
+++ b/drivers/rtc/rtc-pcf8583.c
@@ -320,18 +320,7 @@ static struct i2c_driver pcf8583_driver = {
320 .id_table = pcf8583_id, 320 .id_table = pcf8583_id,
321}; 321};
322 322
323static __init int pcf8583_init(void) 323module_i2c_driver(pcf8583_driver);
324{
325 return i2c_add_driver(&pcf8583_driver);
326}
327
328static __exit void pcf8583_exit(void)
329{
330 i2c_del_driver(&pcf8583_driver);
331}
332
333module_init(pcf8583_init);
334module_exit(pcf8583_exit);
335 324
336MODULE_AUTHOR("Russell King"); 325MODULE_AUTHOR("Russell King");
337MODULE_DESCRIPTION("PCF8583 I2C RTC driver"); 326MODULE_DESCRIPTION("PCF8583 I2C RTC driver");
diff --git a/drivers/rtc/rtc-rs5c372.c b/drivers/rtc/rtc-rs5c372.c
index d29f5432c6e8..fb4842c3544e 100644
--- a/drivers/rtc/rtc-rs5c372.c
+++ b/drivers/rtc/rtc-rs5c372.c
@@ -689,18 +689,7 @@ static struct i2c_driver rs5c372_driver = {
689 .id_table = rs5c372_id, 689 .id_table = rs5c372_id,
690}; 690};
691 691
692static __init int rs5c372_init(void) 692module_i2c_driver(rs5c372_driver);
693{
694 return i2c_add_driver(&rs5c372_driver);
695}
696
697static __exit void rs5c372_exit(void)
698{
699 i2c_del_driver(&rs5c372_driver);
700}
701
702module_init(rs5c372_init);
703module_exit(rs5c372_exit);
704 693
705MODULE_AUTHOR( 694MODULE_AUTHOR(
706 "Pavel Mironchik <pmironchik@optifacio.net>, " 695 "Pavel Mironchik <pmironchik@optifacio.net>, "
diff --git a/drivers/rtc/rtc-rv3029c2.c b/drivers/rtc/rtc-rv3029c2.c
index ea09ff211dc6..0fbe57b2f6d2 100644
--- a/drivers/rtc/rtc-rv3029c2.c
+++ b/drivers/rtc/rtc-rv3029c2.c
@@ -436,18 +436,7 @@ static struct i2c_driver rv3029c2_driver = {
436 .id_table = rv3029c2_id, 436 .id_table = rv3029c2_id,
437}; 437};
438 438
439static int __init rv3029c2_init(void) 439module_i2c_driver(rv3029c2_driver);
440{
441 return i2c_add_driver(&rv3029c2_driver);
442}
443
444static void __exit rv3029c2_exit(void)
445{
446 i2c_del_driver(&rv3029c2_driver);
447}
448
449module_init(rv3029c2_init);
450module_exit(rv3029c2_exit);
451 440
452MODULE_AUTHOR("Gregory Hermant <gregory.hermant@calao-systems.com>"); 441MODULE_AUTHOR("Gregory Hermant <gregory.hermant@calao-systems.com>");
453MODULE_DESCRIPTION("Micro Crystal RV3029C2 RTC driver"); 442MODULE_DESCRIPTION("Micro Crystal RV3029C2 RTC driver");
diff --git a/drivers/rtc/rtc-rx8025.c b/drivers/rtc/rtc-rx8025.c
index fde172fb2abe..0de902dc1cd5 100644
--- a/drivers/rtc/rtc-rx8025.c
+++ b/drivers/rtc/rtc-rx8025.c
@@ -644,19 +644,8 @@ static struct i2c_driver rx8025_driver = {
644 .id_table = rx8025_id, 644 .id_table = rx8025_id,
645}; 645};
646 646
647static int __init rx8025_init(void) 647module_i2c_driver(rx8025_driver);
648{
649 return i2c_add_driver(&rx8025_driver);
650}
651
652static void __exit rx8025_exit(void)
653{
654 i2c_del_driver(&rx8025_driver);
655}
656 648
657MODULE_AUTHOR("Wolfgang Grandegger <wg@grandegger.com>"); 649MODULE_AUTHOR("Wolfgang Grandegger <wg@grandegger.com>");
658MODULE_DESCRIPTION("RX-8025 SA/NB RTC driver"); 650MODULE_DESCRIPTION("RX-8025 SA/NB RTC driver");
659MODULE_LICENSE("GPL"); 651MODULE_LICENSE("GPL");
660
661module_init(rx8025_init);
662module_exit(rx8025_exit);
diff --git a/drivers/rtc/rtc-rx8581.c b/drivers/rtc/rtc-rx8581.c
index 600b890a3c15..d84825124a7a 100644
--- a/drivers/rtc/rtc-rx8581.c
+++ b/drivers/rtc/rtc-rx8581.c
@@ -276,20 +276,9 @@ static struct i2c_driver rx8581_driver = {
276 .id_table = rx8581_id, 276 .id_table = rx8581_id,
277}; 277};
278 278
279static int __init rx8581_init(void) 279module_i2c_driver(rx8581_driver);
280{
281 return i2c_add_driver(&rx8581_driver);
282}
283
284static void __exit rx8581_exit(void)
285{
286 i2c_del_driver(&rx8581_driver);
287}
288 280
289MODULE_AUTHOR("Martyn Welch <martyn.welch@ge.com>"); 281MODULE_AUTHOR("Martyn Welch <martyn.welch@ge.com>");
290MODULE_DESCRIPTION("Epson RX-8581 RTC driver"); 282MODULE_DESCRIPTION("Epson RX-8581 RTC driver");
291MODULE_LICENSE("GPL"); 283MODULE_LICENSE("GPL");
292MODULE_VERSION(DRV_VERSION); 284MODULE_VERSION(DRV_VERSION);
293
294module_init(rx8581_init);
295module_exit(rx8581_exit);
diff --git a/drivers/rtc/rtc-s35390a.c b/drivers/rtc/rtc-s35390a.c
index f789e002c9b0..c9562ceedef3 100644
--- a/drivers/rtc/rtc-s35390a.c
+++ b/drivers/rtc/rtc-s35390a.c
@@ -304,19 +304,8 @@ static struct i2c_driver s35390a_driver = {
304 .id_table = s35390a_id, 304 .id_table = s35390a_id,
305}; 305};
306 306
307static int __init s35390a_rtc_init(void) 307module_i2c_driver(s35390a_driver);
308{
309 return i2c_add_driver(&s35390a_driver);
310}
311
312static void __exit s35390a_rtc_exit(void)
313{
314 i2c_del_driver(&s35390a_driver);
315}
316 308
317MODULE_AUTHOR("Byron Bradley <byron.bbradley@gmail.com>"); 309MODULE_AUTHOR("Byron Bradley <byron.bbradley@gmail.com>");
318MODULE_DESCRIPTION("S35390A RTC driver"); 310MODULE_DESCRIPTION("S35390A RTC driver");
319MODULE_LICENSE("GPL"); 311MODULE_LICENSE("GPL");
320
321module_init(s35390a_rtc_init);
322module_exit(s35390a_rtc_exit);
diff --git a/drivers/rtc/rtc-x1205.c b/drivers/rtc/rtc-x1205.c
index 8c051d3179db..403b3d41d101 100644
--- a/drivers/rtc/rtc-x1205.c
+++ b/drivers/rtc/rtc-x1205.c
@@ -623,15 +623,7 @@ static struct i2c_driver x1205_driver = {
623 .id_table = x1205_id, 623 .id_table = x1205_id,
624}; 624};
625 625
626static int __init x1205_init(void) 626module_i2c_driver(x1205_driver);
627{
628 return i2c_add_driver(&x1205_driver);
629}
630
631static void __exit x1205_exit(void)
632{
633 i2c_del_driver(&x1205_driver);
634}
635 627
636MODULE_AUTHOR( 628MODULE_AUTHOR(
637 "Karen Spearel <kas111 at gmail dot com>, " 629 "Karen Spearel <kas111 at gmail dot com>, "
@@ -639,6 +631,3 @@ MODULE_AUTHOR(
639MODULE_DESCRIPTION("Xicor/Intersil X1205 RTC driver"); 631MODULE_DESCRIPTION("Xicor/Intersil X1205 RTC driver");
640MODULE_LICENSE("GPL"); 632MODULE_LICENSE("GPL");
641MODULE_VERSION(DRV_VERSION); 633MODULE_VERSION(DRV_VERSION);
642
643module_init(x1205_init);
644module_exit(x1205_exit);