aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/storage
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2011-11-18 12:34:02 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2011-11-18 12:34:02 -0500
commit65db43054065790a75291b0834657445fea2cf56 (patch)
tree000b010ed36dc99c4695178a6cb8a797a3d24865 /drivers/usb/storage
parentf3a6a4b6cfc80e57bf16bb12f9425bec1a5731a9 (diff)
USB: convert drivers/usb/* to use module_usb_driver()
This converts the drivers in drivers/usb/* to use the module_usb_driver() macro which makes the code smaller and a bit simpler. Added bonus is that it removes some unneeded kernel log messages about drivers loading and/or unloading. Cc: Simon Arlott <cxacru@fire.lp0.eu> Cc: Duncan Sands <duncan.sands@free.fr> Cc: Matthieu CASTET <castet.matthieu@free.fr> Cc: Stanislaw Gruszka <stf_xl@wp.pl> Cc: Pete Zaitcev <zaitcev@redhat.com> Cc: Oliver Neukum <oliver@neukum.name> Cc: Juergen Stuber <starblue@users.sourceforge.net> Cc: Cesar Miquel <miquel@df.uba.ar> Cc: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Cc: Matthew Wilcox <willy@linux.intel.com> Cc: Sarah Sharp <sarah.a.sharp@linux.intel.com> Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Cc: Felipe Balbi <balbi@ti.com> Cc: Lucas De Marchi <lucas.demarchi@profusion.mobi> Cc: Michael Hund <mhund@ld-didactic.de> Cc: Zack Parsons <k3bacon@gmail.com> Cc: Melchior FRANZ <mfranz@aon.at> Cc: Tomoki Sekiyama <tomoki.sekiyama@gmail.com> Cc: Dan Carpenter <error27@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/storage')
-rw-r--r--drivers/usb/storage/alauda.c13
-rw-r--r--drivers/usb/storage/cypress_atacb.c13
-rw-r--r--drivers/usb/storage/datafab.c13
-rw-r--r--drivers/usb/storage/ene_ub6250.c13
-rw-r--r--drivers/usb/storage/freecom.c13
-rw-r--r--drivers/usb/storage/isd200.c13
-rw-r--r--drivers/usb/storage/jumpshot.c13
-rw-r--r--drivers/usb/storage/karma.c13
-rw-r--r--drivers/usb/storage/onetouch.c13
-rw-r--r--drivers/usb/storage/realtek_cr.c13
-rw-r--r--drivers/usb/storage/sddr09.c13
-rw-r--r--drivers/usb/storage/sddr55.c13
-rw-r--r--drivers/usb/storage/shuttle_usbat.c13
-rw-r--r--drivers/usb/storage/uas.c13
14 files changed, 14 insertions, 168 deletions
diff --git a/drivers/usb/storage/alauda.c b/drivers/usb/storage/alauda.c
index 42d0eaed4a01..3ca87a823342 100644
--- a/drivers/usb/storage/alauda.c
+++ b/drivers/usb/storage/alauda.c
@@ -1278,15 +1278,4 @@ static struct usb_driver alauda_driver = {
1278 .soft_unbind = 1, 1278 .soft_unbind = 1,
1279}; 1279};
1280 1280
1281static int __init alauda_init(void) 1281module_usb_driver(alauda_driver);
1282{
1283 return usb_register(&alauda_driver);
1284}
1285
1286static void __exit alauda_exit(void)
1287{
1288 usb_deregister(&alauda_driver);
1289}
1290
1291module_init(alauda_init);
1292module_exit(alauda_exit);
diff --git a/drivers/usb/storage/cypress_atacb.c b/drivers/usb/storage/cypress_atacb.c
index c84471821183..c7909dfa2434 100644
--- a/drivers/usb/storage/cypress_atacb.c
+++ b/drivers/usb/storage/cypress_atacb.c
@@ -274,15 +274,4 @@ static struct usb_driver cypress_driver = {
274 .soft_unbind = 1, 274 .soft_unbind = 1,
275}; 275};
276 276
277static int __init cypress_init(void) 277module_usb_driver(cypress_driver);
278{
279 return usb_register(&cypress_driver);
280}
281
282static void __exit cypress_exit(void)
283{
284 usb_deregister(&cypress_driver);
285}
286
287module_init(cypress_init);
288module_exit(cypress_exit);
diff --git a/drivers/usb/storage/datafab.c b/drivers/usb/storage/datafab.c
index ded836b02d7b..a99be857b794 100644
--- a/drivers/usb/storage/datafab.c
+++ b/drivers/usb/storage/datafab.c
@@ -753,15 +753,4 @@ static struct usb_driver datafab_driver = {
753 .soft_unbind = 1, 753 .soft_unbind = 1,
754}; 754};
755 755
756static int __init datafab_init(void) 756module_usb_driver(datafab_driver);
757{
758 return usb_register(&datafab_driver);
759}
760
761static void __exit datafab_exit(void)
762{
763 usb_deregister(&datafab_driver);
764}
765
766module_init(datafab_init);
767module_exit(datafab_exit);
diff --git a/drivers/usb/storage/ene_ub6250.c b/drivers/usb/storage/ene_ub6250.c
index 4dca3ef0668c..5929f49d0b43 100644
--- a/drivers/usb/storage/ene_ub6250.c
+++ b/drivers/usb/storage/ene_ub6250.c
@@ -2410,15 +2410,4 @@ static struct usb_driver ene_ub6250_driver = {
2410 .soft_unbind = 1, 2410 .soft_unbind = 1,
2411}; 2411};
2412 2412
2413static int __init ene_ub6250_init(void) 2413module_usb_driver(ene_ub6250_driver);
2414{
2415 return usb_register(&ene_ub6250_driver);
2416}
2417
2418static void __exit ene_ub6250_exit(void)
2419{
2420 usb_deregister(&ene_ub6250_driver);
2421}
2422
2423module_init(ene_ub6250_init);
2424module_exit(ene_ub6250_exit);
diff --git a/drivers/usb/storage/freecom.c b/drivers/usb/storage/freecom.c
index 6542ca40d505..03d4a873748c 100644
--- a/drivers/usb/storage/freecom.c
+++ b/drivers/usb/storage/freecom.c
@@ -555,15 +555,4 @@ static struct usb_driver freecom_driver = {
555 .soft_unbind = 1, 555 .soft_unbind = 1,
556}; 556};
557 557
558static int __init freecom_init(void) 558module_usb_driver(freecom_driver);
559{
560 return usb_register(&freecom_driver);
561}
562
563static void __exit freecom_exit(void)
564{
565 usb_deregister(&freecom_driver);
566}
567
568module_init(freecom_init);
569module_exit(freecom_exit);
diff --git a/drivers/usb/storage/isd200.c b/drivers/usb/storage/isd200.c
index ffc4193e9505..6d6923317f10 100644
--- a/drivers/usb/storage/isd200.c
+++ b/drivers/usb/storage/isd200.c
@@ -1568,15 +1568,4 @@ static struct usb_driver isd200_driver = {
1568 .soft_unbind = 1, 1568 .soft_unbind = 1,
1569}; 1569};
1570 1570
1571static int __init isd200_init(void) 1571module_usb_driver(isd200_driver);
1572{
1573 return usb_register(&isd200_driver);
1574}
1575
1576static void __exit isd200_exit(void)
1577{
1578 usb_deregister(&isd200_driver);
1579}
1580
1581module_init(isd200_init);
1582module_exit(isd200_exit);
diff --git a/drivers/usb/storage/jumpshot.c b/drivers/usb/storage/jumpshot.c
index 6168596c5ac6..54b71650b69c 100644
--- a/drivers/usb/storage/jumpshot.c
+++ b/drivers/usb/storage/jumpshot.c
@@ -679,15 +679,4 @@ static struct usb_driver jumpshot_driver = {
679 .soft_unbind = 1, 679 .soft_unbind = 1,
680}; 680};
681 681
682static int __init jumpshot_init(void) 682module_usb_driver(jumpshot_driver);
683{
684 return usb_register(&jumpshot_driver);
685}
686
687static void __exit jumpshot_exit(void)
688{
689 usb_deregister(&jumpshot_driver);
690}
691
692module_init(jumpshot_init);
693module_exit(jumpshot_exit);
diff --git a/drivers/usb/storage/karma.c b/drivers/usb/storage/karma.c
index ba1b78906880..35181e29124d 100644
--- a/drivers/usb/storage/karma.c
+++ b/drivers/usb/storage/karma.c
@@ -232,15 +232,4 @@ static struct usb_driver karma_driver = {
232 .soft_unbind = 1, 232 .soft_unbind = 1,
233}; 233};
234 234
235static int __init karma_init(void) 235module_usb_driver(karma_driver);
236{
237 return usb_register(&karma_driver);
238}
239
240static void __exit karma_exit(void)
241{
242 usb_deregister(&karma_driver);
243}
244
245module_init(karma_init);
246module_exit(karma_exit);
diff --git a/drivers/usb/storage/onetouch.c b/drivers/usb/storage/onetouch.c
index 1943be5a2914..721c8c587305 100644
--- a/drivers/usb/storage/onetouch.c
+++ b/drivers/usb/storage/onetouch.c
@@ -314,15 +314,4 @@ static struct usb_driver onetouch_driver = {
314 .soft_unbind = 1, 314 .soft_unbind = 1,
315}; 315};
316 316
317static int __init onetouch_init(void) 317module_usb_driver(onetouch_driver);
318{
319 return usb_register(&onetouch_driver);
320}
321
322static void __exit onetouch_exit(void)
323{
324 usb_deregister(&onetouch_driver);
325}
326
327module_init(onetouch_init);
328module_exit(onetouch_exit);
diff --git a/drivers/usb/storage/realtek_cr.c b/drivers/usb/storage/realtek_cr.c
index 0ce5f79197e7..c41cd30d2c01 100644
--- a/drivers/usb/storage/realtek_cr.c
+++ b/drivers/usb/storage/realtek_cr.c
@@ -1104,15 +1104,4 @@ static struct usb_driver realtek_cr_driver = {
1104 .supports_autosuspend = 1, 1104 .supports_autosuspend = 1,
1105}; 1105};
1106 1106
1107static int __init realtek_cr_init(void) 1107module_usb_driver(realtek_cr_driver);
1108{
1109 return usb_register(&realtek_cr_driver);
1110}
1111
1112static void __exit realtek_cr_exit(void)
1113{
1114 usb_deregister(&realtek_cr_driver);
1115}
1116
1117module_init(realtek_cr_init);
1118module_exit(realtek_cr_exit);
diff --git a/drivers/usb/storage/sddr09.c b/drivers/usb/storage/sddr09.c
index bcb9a709d349..83ee49e737bd 100644
--- a/drivers/usb/storage/sddr09.c
+++ b/drivers/usb/storage/sddr09.c
@@ -1789,15 +1789,4 @@ static struct usb_driver sddr09_driver = {
1789 .soft_unbind = 1, 1789 .soft_unbind = 1,
1790}; 1790};
1791 1791
1792static int __init sddr09_init(void) 1792module_usb_driver(sddr09_driver);
1793{
1794 return usb_register(&sddr09_driver);
1795}
1796
1797static void __exit sddr09_exit(void)
1798{
1799 usb_deregister(&sddr09_driver);
1800}
1801
1802module_init(sddr09_init);
1803module_exit(sddr09_exit);
diff --git a/drivers/usb/storage/sddr55.c b/drivers/usb/storage/sddr55.c
index 44dfed7754ed..8983ec2ffb5a 100644
--- a/drivers/usb/storage/sddr55.c
+++ b/drivers/usb/storage/sddr55.c
@@ -1008,15 +1008,4 @@ static struct usb_driver sddr55_driver = {
1008 .soft_unbind = 1, 1008 .soft_unbind = 1,
1009}; 1009};
1010 1010
1011static int __init sddr55_init(void) 1011module_usb_driver(sddr55_driver);
1012{
1013 return usb_register(&sddr55_driver);
1014}
1015
1016static void __exit sddr55_exit(void)
1017{
1018 usb_deregister(&sddr55_driver);
1019}
1020
1021module_init(sddr55_init);
1022module_exit(sddr55_exit);
diff --git a/drivers/usb/storage/shuttle_usbat.c b/drivers/usb/storage/shuttle_usbat.c
index 0b00091d2ae9..a4c02751af4e 100644
--- a/drivers/usb/storage/shuttle_usbat.c
+++ b/drivers/usb/storage/shuttle_usbat.c
@@ -1865,15 +1865,4 @@ static struct usb_driver usbat_driver = {
1865 .soft_unbind = 1, 1865 .soft_unbind = 1,
1866}; 1866};
1867 1867
1868static int __init usbat_init(void) 1868module_usb_driver(usbat_driver);
1869{
1870 return usb_register(&usbat_driver);
1871}
1872
1873static void __exit usbat_exit(void)
1874{
1875 usb_deregister(&usbat_driver);
1876}
1877
1878module_init(usbat_init);
1879module_exit(usbat_exit);
diff --git a/drivers/usb/storage/uas.c b/drivers/usb/storage/uas.c
index 1d10d5b8204c..a33ead5dce20 100644
--- a/drivers/usb/storage/uas.c
+++ b/drivers/usb/storage/uas.c
@@ -760,18 +760,7 @@ static struct usb_driver uas_driver = {
760 .id_table = uas_usb_ids, 760 .id_table = uas_usb_ids,
761}; 761};
762 762
763static int uas_init(void) 763module_usb_driver(uas_driver);
764{
765 return usb_register(&uas_driver);
766}
767
768static void uas_exit(void)
769{
770 usb_deregister(&uas_driver);
771}
772
773module_init(uas_init);
774module_exit(uas_exit);
775 764
776MODULE_LICENSE("GPL"); 765MODULE_LICENSE("GPL");
777MODULE_AUTHOR("Matthew Wilcox and Sarah Sharp"); 766MODULE_AUTHOR("Matthew Wilcox and Sarah Sharp");