diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2011-11-18 12:46:12 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-11-18 12:46:12 -0500 |
commit | ecb3b2b35db49778b6d89e3ffd0c400776c20735 (patch) | |
tree | cdec945a8b6651154633b986a318d0441ff3c239 /drivers/media/video | |
parent | d632eb1bf22e11def74e4e53cc47d790fbdba105 (diff) |
USB: convert drivers/media/* to use module_usb_driver()
This converts the drivers in drivers/media/* 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: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: Luca Risolia <luca.risolia@studio.unibo.it>
Cc: Jean-Francois Moine <moinejf@free.fr>
Cc: Frank Zago <frank@zago.net>
Cc: Olivier Lorin <o.lorin@laposte.net>
Cc: Erik Andren <erik.andren@gmail.com>
Cc: Hans de Goede <hdegoede@redhat.com>
Cc: Brian Johnson <brijohn@gmail.com>
Cc: Leandro Costantino <lcostantino@gmail.com>
Cc: Antoine Jacquet <royale@zerezo.com>
Cc: Jarod Wilson <jarod@redhat.com>
Cc: Florian Mickler <florian@mickler.org>
Cc: Antti Palosaari <crope@iki.fi>
Cc: Michael Krufky <mkrufky@kernellabs.com>
Cc: "David Härdeman" <david@hardeman.nu>
Cc: Florent Audebert <florent.audebert@anevia.com>
Cc: Sam Doshi <sam@metal-fish.co.uk>
Cc: Manu Abraham <manu@linuxtv.org>
Cc: Olivier Grenie <olivier.grenie@dibcom.fr>
Cc: Patrick Boettcher <patrick.boettcher@dibcom.fr>
Cc: "Igor M. Liplianin" <liplianin@me.by>
Cc: Derek Kelly <user.vdr@gmail.com>
Cc: Malcolm Priestley <tvboxspy@gmail.com>
Cc: Steven Toth <stoth@kernellabs.com>
Cc: "André Weidemann" <Andre.Weidemann@web.de>
Cc: Martin Wilks <m.wilks@technisat.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Jose Alberto Reguero <jareguero@telefonica.net>
Cc: David Henningsson <david.henningsson@canonical.com>
Cc: Paul Gortmaker <paul.gortmaker@windriver.com>
Cc: Joe Perches <joe@perches.com>
Cc: Jesper Juhl <jj@chaosbits.net>
Cc: Lucas De Marchi <lucas.demarchi@profusion.mobi>
Cc: Hans Verkuil <hans.verkuil@cisco.com>
Cc: Alexey Khoroshilov <khoroshilov@ispras.ru>
Cc: Anssi Hannula <anssi.hannula@iki.fi>
Cc: Rafi Rubin <rafi@seas.upenn.edu>
Cc: Dan Carpenter <error27@gmail.com>
Cc: Paul Bender <pebender@gmail.com>
Cc: Devin Heitmueller <dheitmueller@kernellabs.com>
Cc: "Márcio A Alves" <froooozen@gmail.com>
Cc: Julia Lawall <julia@diku.dk>
Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Chris Rankin <rankincj@yahoo.com>
Cc: Lee Jones <lee.jones@canonical.com>
Cc: Andy Walls <awalls@md.metrocast.net>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Mike Frysinger <vapier@gentoo.org>
Cc: Dean Anderson <linux-dev@sensoray.com>
Cc: Pete Eberlein <pete@sensoray.com>
Cc: Arvydas Sidorenko <asido4@gmail.com>
Cc: Andrea Anacleto <andreaanacleto@libero.it>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/media/video')
54 files changed, 54 insertions, 764 deletions
diff --git a/drivers/media/video/cx231xx/cx231xx-cards.c b/drivers/media/video/cx231xx/cx231xx-cards.c index 53dae2a8272d..60b021e79864 100644 --- a/drivers/media/video/cx231xx/cx231xx-cards.c +++ b/drivers/media/video/cx231xx/cx231xx-cards.c | |||
@@ -1385,26 +1385,4 @@ static struct usb_driver cx231xx_usb_driver = { | |||
1385 | .id_table = cx231xx_id_table, | 1385 | .id_table = cx231xx_id_table, |
1386 | }; | 1386 | }; |
1387 | 1387 | ||
1388 | static int __init cx231xx_module_init(void) | 1388 | module_usb_driver(cx231xx_usb_driver); |
1389 | { | ||
1390 | int result; | ||
1391 | |||
1392 | printk(KERN_INFO DRIVER_NAME " v4l2 driver loaded.\n"); | ||
1393 | |||
1394 | /* register this driver with the USB subsystem */ | ||
1395 | result = usb_register(&cx231xx_usb_driver); | ||
1396 | if (result) | ||
1397 | cx231xx_err(DRIVER_NAME | ||
1398 | " usb_register failed. Error number %d.\n", result); | ||
1399 | |||
1400 | return result; | ||
1401 | } | ||
1402 | |||
1403 | static void __exit cx231xx_module_exit(void) | ||
1404 | { | ||
1405 | /* deregister this driver with the USB subsystem */ | ||
1406 | usb_deregister(&cx231xx_usb_driver); | ||
1407 | } | ||
1408 | |||
1409 | module_init(cx231xx_module_init); | ||
1410 | module_exit(cx231xx_module_exit); | ||
diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c index 9b747c266afa..93807dcf944e 100644 --- a/drivers/media/video/em28xx/em28xx-cards.c +++ b/drivers/media/video/em28xx/em28xx-cards.c | |||
@@ -3325,26 +3325,4 @@ static struct usb_driver em28xx_usb_driver = { | |||
3325 | .id_table = em28xx_id_table, | 3325 | .id_table = em28xx_id_table, |
3326 | }; | 3326 | }; |
3327 | 3327 | ||
3328 | static int __init em28xx_module_init(void) | 3328 | module_usb_driver(em28xx_usb_driver); |
3329 | { | ||
3330 | int result; | ||
3331 | |||
3332 | /* register this driver with the USB subsystem */ | ||
3333 | result = usb_register(&em28xx_usb_driver); | ||
3334 | if (result) | ||
3335 | em28xx_err(DRIVER_NAME | ||
3336 | " usb_register failed. Error number %d.\n", result); | ||
3337 | |||
3338 | printk(KERN_INFO DRIVER_NAME " driver loaded\n"); | ||
3339 | |||
3340 | return result; | ||
3341 | } | ||
3342 | |||
3343 | static void __exit em28xx_module_exit(void) | ||
3344 | { | ||
3345 | /* deregister this driver with the USB subsystem */ | ||
3346 | usb_deregister(&em28xx_usb_driver); | ||
3347 | } | ||
3348 | |||
3349 | module_init(em28xx_module_init); | ||
3350 | module_exit(em28xx_module_exit); | ||
diff --git a/drivers/media/video/et61x251/et61x251_core.c b/drivers/media/video/et61x251/et61x251_core.c index d3777c86e1de..40f214ab924f 100644 --- a/drivers/media/video/et61x251/et61x251_core.c +++ b/drivers/media/video/et61x251/et61x251_core.c | |||
@@ -2680,27 +2680,4 @@ static struct usb_driver et61x251_usb_driver = { | |||
2680 | .disconnect = et61x251_usb_disconnect, | 2680 | .disconnect = et61x251_usb_disconnect, |
2681 | }; | 2681 | }; |
2682 | 2682 | ||
2683 | /*****************************************************************************/ | 2683 | module_usb_driver(et61x251_usb_driver); |
2684 | |||
2685 | static int __init et61x251_module_init(void) | ||
2686 | { | ||
2687 | int err = 0; | ||
2688 | |||
2689 | KDBG(2, ET61X251_MODULE_NAME " v" ET61X251_MODULE_VERSION); | ||
2690 | KDBG(3, ET61X251_MODULE_AUTHOR); | ||
2691 | |||
2692 | if ((err = usb_register(&et61x251_usb_driver))) | ||
2693 | KDBG(1, "usb_register() failed"); | ||
2694 | |||
2695 | return err; | ||
2696 | } | ||
2697 | |||
2698 | |||
2699 | static void __exit et61x251_module_exit(void) | ||
2700 | { | ||
2701 | usb_deregister(&et61x251_usb_driver); | ||
2702 | } | ||
2703 | |||
2704 | |||
2705 | module_init(et61x251_module_init); | ||
2706 | module_exit(et61x251_module_exit); | ||
diff --git a/drivers/media/video/gspca/benq.c b/drivers/media/video/gspca/benq.c index 6ae26160b81f..636627b57dc9 100644 --- a/drivers/media/video/gspca/benq.c +++ b/drivers/media/video/gspca/benq.c | |||
@@ -288,15 +288,4 @@ static struct usb_driver sd_driver = { | |||
288 | #endif | 288 | #endif |
289 | }; | 289 | }; |
290 | 290 | ||
291 | /* -- module insert / remove -- */ | 291 | module_usb_driver(sd_driver); |
292 | static int __init sd_mod_init(void) | ||
293 | { | ||
294 | return usb_register(&sd_driver); | ||
295 | } | ||
296 | static void __exit sd_mod_exit(void) | ||
297 | { | ||
298 | usb_deregister(&sd_driver); | ||
299 | } | ||
300 | |||
301 | module_init(sd_mod_init); | ||
302 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/conex.c b/drivers/media/video/gspca/conex.c index 4c56dbef6d92..ea17b5d94ea4 100644 --- a/drivers/media/video/gspca/conex.c +++ b/drivers/media/video/gspca/conex.c | |||
@@ -1067,15 +1067,4 @@ static struct usb_driver sd_driver = { | |||
1067 | #endif | 1067 | #endif |
1068 | }; | 1068 | }; |
1069 | 1069 | ||
1070 | /* -- module insert / remove -- */ | 1070 | module_usb_driver(sd_driver); |
1071 | static int __init sd_mod_init(void) | ||
1072 | { | ||
1073 | return usb_register(&sd_driver); | ||
1074 | } | ||
1075 | static void __exit sd_mod_exit(void) | ||
1076 | { | ||
1077 | usb_deregister(&sd_driver); | ||
1078 | } | ||
1079 | |||
1080 | module_init(sd_mod_init); | ||
1081 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/cpia1.c b/drivers/media/video/gspca/cpia1.c index f9b86b2484b0..8f33bbd091ad 100644 --- a/drivers/media/video/gspca/cpia1.c +++ b/drivers/media/video/gspca/cpia1.c | |||
@@ -2132,15 +2132,4 @@ static struct usb_driver sd_driver = { | |||
2132 | #endif | 2132 | #endif |
2133 | }; | 2133 | }; |
2134 | 2134 | ||
2135 | /* -- module insert / remove -- */ | 2135 | module_usb_driver(sd_driver); |
2136 | static int __init sd_mod_init(void) | ||
2137 | { | ||
2138 | return usb_register(&sd_driver); | ||
2139 | } | ||
2140 | static void __exit sd_mod_exit(void) | ||
2141 | { | ||
2142 | usb_deregister(&sd_driver); | ||
2143 | } | ||
2144 | |||
2145 | module_init(sd_mod_init); | ||
2146 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/etoms.c b/drivers/media/video/gspca/etoms.c index 0357d6d461d1..81a4adbd9f7c 100644 --- a/drivers/media/video/gspca/etoms.c +++ b/drivers/media/video/gspca/etoms.c | |||
@@ -895,16 +895,4 @@ static struct usb_driver sd_driver = { | |||
895 | #endif | 895 | #endif |
896 | }; | 896 | }; |
897 | 897 | ||
898 | /* -- module insert / remove -- */ | 898 | module_usb_driver(sd_driver); |
899 | static int __init sd_mod_init(void) | ||
900 | { | ||
901 | return usb_register(&sd_driver); | ||
902 | } | ||
903 | |||
904 | static void __exit sd_mod_exit(void) | ||
905 | { | ||
906 | usb_deregister(&sd_driver); | ||
907 | } | ||
908 | |||
909 | module_init(sd_mod_init); | ||
910 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/finepix.c b/drivers/media/video/gspca/finepix.c index ea48200fd3a0..0107513cd728 100644 --- a/drivers/media/video/gspca/finepix.c +++ b/drivers/media/video/gspca/finepix.c | |||
@@ -290,16 +290,4 @@ static struct usb_driver sd_driver = { | |||
290 | #endif | 290 | #endif |
291 | }; | 291 | }; |
292 | 292 | ||
293 | /* -- module insert / remove -- */ | 293 | module_usb_driver(sd_driver); |
294 | static int __init sd_mod_init(void) | ||
295 | { | ||
296 | return usb_register(&sd_driver); | ||
297 | } | ||
298 | |||
299 | static void __exit sd_mod_exit(void) | ||
300 | { | ||
301 | usb_deregister(&sd_driver); | ||
302 | } | ||
303 | |||
304 | module_init(sd_mod_init); | ||
305 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/gl860/gl860.c b/drivers/media/video/gspca/gl860/gl860.c index 2ced3b73994f..a8f54c20e585 100644 --- a/drivers/media/video/gspca/gl860/gl860.c +++ b/drivers/media/video/gspca/gl860/gl860.c | |||
@@ -524,22 +524,7 @@ static struct usb_driver sd_driver = { | |||
524 | 524 | ||
525 | /*====================== Init and Exit module functions ====================*/ | 525 | /*====================== Init and Exit module functions ====================*/ |
526 | 526 | ||
527 | static int __init sd_mod_init(void) | 527 | module_usb_driver(sd_driver); |
528 | { | ||
529 | PDEBUG(D_PROBE, "driver startup - version %s", DRIVER_VERSION); | ||
530 | |||
531 | if (usb_register(&sd_driver) < 0) | ||
532 | return -1; | ||
533 | return 0; | ||
534 | } | ||
535 | |||
536 | static void __exit sd_mod_exit(void) | ||
537 | { | ||
538 | usb_deregister(&sd_driver); | ||
539 | } | ||
540 | |||
541 | module_init(sd_mod_init); | ||
542 | module_exit(sd_mod_exit); | ||
543 | 528 | ||
544 | /*==========================================================================*/ | 529 | /*==========================================================================*/ |
545 | 530 | ||
diff --git a/drivers/media/video/gspca/jeilinj.c b/drivers/media/video/gspca/jeilinj.c index 8e3dabe30077..5ab3f7e12760 100644 --- a/drivers/media/video/gspca/jeilinj.c +++ b/drivers/media/video/gspca/jeilinj.c | |||
@@ -582,16 +582,4 @@ static struct usb_driver sd_driver = { | |||
582 | #endif | 582 | #endif |
583 | }; | 583 | }; |
584 | 584 | ||
585 | /* -- module insert / remove -- */ | 585 | module_usb_driver(sd_driver); |
586 | static int __init sd_mod_init(void) | ||
587 | { | ||
588 | return usb_register(&sd_driver); | ||
589 | } | ||
590 | |||
591 | static void __exit sd_mod_exit(void) | ||
592 | { | ||
593 | usb_deregister(&sd_driver); | ||
594 | } | ||
595 | |||
596 | module_init(sd_mod_init); | ||
597 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/kinect.c b/drivers/media/video/gspca/kinect.c index 4fe51fda80f3..e8e8f2fe9166 100644 --- a/drivers/media/video/gspca/kinect.c +++ b/drivers/media/video/gspca/kinect.c | |||
@@ -413,16 +413,4 @@ static struct usb_driver sd_driver = { | |||
413 | #endif | 413 | #endif |
414 | }; | 414 | }; |
415 | 415 | ||
416 | /* -- module insert / remove -- */ | 416 | module_usb_driver(sd_driver); |
417 | static int __init sd_mod_init(void) | ||
418 | { | ||
419 | return usb_register(&sd_driver); | ||
420 | } | ||
421 | |||
422 | static void __exit sd_mod_exit(void) | ||
423 | { | ||
424 | usb_deregister(&sd_driver); | ||
425 | } | ||
426 | |||
427 | module_init(sd_mod_init); | ||
428 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/konica.c b/drivers/media/video/gspca/konica.c index f3f7fe0ec4b7..b1da7f4096c8 100644 --- a/drivers/media/video/gspca/konica.c +++ b/drivers/media/video/gspca/konica.c | |||
@@ -634,15 +634,4 @@ static struct usb_driver sd_driver = { | |||
634 | #endif | 634 | #endif |
635 | }; | 635 | }; |
636 | 636 | ||
637 | /* -- module insert / remove -- */ | 637 | module_usb_driver(sd_driver); |
638 | static int __init sd_mod_init(void) | ||
639 | { | ||
640 | return usb_register(&sd_driver); | ||
641 | } | ||
642 | static void __exit sd_mod_exit(void) | ||
643 | { | ||
644 | usb_deregister(&sd_driver); | ||
645 | } | ||
646 | |||
647 | module_init(sd_mod_init); | ||
648 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/m5602/m5602_core.c b/drivers/media/video/gspca/m5602/m5602_core.c index 67533e5582a6..9fe3816b2aa0 100644 --- a/drivers/media/video/gspca/m5602/m5602_core.c +++ b/drivers/media/video/gspca/m5602/m5602_core.c | |||
@@ -404,19 +404,7 @@ static struct usb_driver sd_driver = { | |||
404 | .disconnect = m5602_disconnect | 404 | .disconnect = m5602_disconnect |
405 | }; | 405 | }; |
406 | 406 | ||
407 | /* -- module insert / remove -- */ | 407 | module_usb_driver(sd_driver); |
408 | static int __init mod_m5602_init(void) | ||
409 | { | ||
410 | return usb_register(&sd_driver); | ||
411 | } | ||
412 | |||
413 | static void __exit mod_m5602_exit(void) | ||
414 | { | ||
415 | usb_deregister(&sd_driver); | ||
416 | } | ||
417 | |||
418 | module_init(mod_m5602_init); | ||
419 | module_exit(mod_m5602_exit); | ||
420 | 408 | ||
421 | MODULE_AUTHOR(DRIVER_AUTHOR); | 409 | MODULE_AUTHOR(DRIVER_AUTHOR); |
422 | MODULE_DESCRIPTION(DRIVER_DESC); | 410 | MODULE_DESCRIPTION(DRIVER_DESC); |
diff --git a/drivers/media/video/gspca/mars.c b/drivers/media/video/gspca/mars.c index ef45fa575752..5c2ea05c46b4 100644 --- a/drivers/media/video/gspca/mars.c +++ b/drivers/media/video/gspca/mars.c | |||
@@ -517,15 +517,4 @@ static struct usb_driver sd_driver = { | |||
517 | #endif | 517 | #endif |
518 | }; | 518 | }; |
519 | 519 | ||
520 | /* -- module insert / remove -- */ | 520 | module_usb_driver(sd_driver); |
521 | static int __init sd_mod_init(void) | ||
522 | { | ||
523 | return usb_register(&sd_driver); | ||
524 | } | ||
525 | static void __exit sd_mod_exit(void) | ||
526 | { | ||
527 | usb_deregister(&sd_driver); | ||
528 | } | ||
529 | |||
530 | module_init(sd_mod_init); | ||
531 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/mr97310a.c b/drivers/media/video/gspca/mr97310a.c index 473e813b680e..d73e5bd3dbf7 100644 --- a/drivers/media/video/gspca/mr97310a.c +++ b/drivers/media/video/gspca/mr97310a.c | |||
@@ -1259,15 +1259,4 @@ static struct usb_driver sd_driver = { | |||
1259 | #endif | 1259 | #endif |
1260 | }; | 1260 | }; |
1261 | 1261 | ||
1262 | /* -- module insert / remove -- */ | 1262 | module_usb_driver(sd_driver); |
1263 | static int __init sd_mod_init(void) | ||
1264 | { | ||
1265 | return usb_register(&sd_driver); | ||
1266 | } | ||
1267 | static void __exit sd_mod_exit(void) | ||
1268 | { | ||
1269 | usb_deregister(&sd_driver); | ||
1270 | } | ||
1271 | |||
1272 | module_init(sd_mod_init); | ||
1273 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/nw80x.c b/drivers/media/video/gspca/nw80x.c index 7681814e594f..d4bec9321771 100644 --- a/drivers/media/video/gspca/nw80x.c +++ b/drivers/media/video/gspca/nw80x.c | |||
@@ -2118,18 +2118,7 @@ static struct usb_driver sd_driver = { | |||
2118 | #endif | 2118 | #endif |
2119 | }; | 2119 | }; |
2120 | 2120 | ||
2121 | /* -- module insert / remove -- */ | 2121 | module_usb_driver(sd_driver); |
2122 | static int __init sd_mod_init(void) | ||
2123 | { | ||
2124 | return usb_register(&sd_driver); | ||
2125 | } | ||
2126 | static void __exit sd_mod_exit(void) | ||
2127 | { | ||
2128 | usb_deregister(&sd_driver); | ||
2129 | } | ||
2130 | |||
2131 | module_init(sd_mod_init); | ||
2132 | module_exit(sd_mod_exit); | ||
2133 | 2122 | ||
2134 | module_param(webcam, int, 0644); | 2123 | module_param(webcam, int, 0644); |
2135 | MODULE_PARM_DESC(webcam, | 2124 | MODULE_PARM_DESC(webcam, |
diff --git a/drivers/media/video/gspca/ov519.c b/drivers/media/video/gspca/ov519.c index 6a01b35a9478..08b8ce1dee18 100644 --- a/drivers/media/video/gspca/ov519.c +++ b/drivers/media/video/gspca/ov519.c | |||
@@ -5056,18 +5056,7 @@ static struct usb_driver sd_driver = { | |||
5056 | #endif | 5056 | #endif |
5057 | }; | 5057 | }; |
5058 | 5058 | ||
5059 | /* -- module insert / remove -- */ | 5059 | module_usb_driver(sd_driver); |
5060 | static int __init sd_mod_init(void) | ||
5061 | { | ||
5062 | return usb_register(&sd_driver); | ||
5063 | } | ||
5064 | static void __exit sd_mod_exit(void) | ||
5065 | { | ||
5066 | usb_deregister(&sd_driver); | ||
5067 | } | ||
5068 | |||
5069 | module_init(sd_mod_init); | ||
5070 | module_exit(sd_mod_exit); | ||
5071 | 5060 | ||
5072 | module_param(frame_rate, int, 0644); | 5061 | module_param(frame_rate, int, 0644); |
5073 | MODULE_PARM_DESC(frame_rate, "Frame rate (5, 10, 15, 20 or 30 fps)"); | 5062 | MODULE_PARM_DESC(frame_rate, "Frame rate (5, 10, 15, 20 or 30 fps)"); |
diff --git a/drivers/media/video/gspca/ov534.c b/drivers/media/video/gspca/ov534.c index 76907eced4a1..04753391de3e 100644 --- a/drivers/media/video/gspca/ov534.c +++ b/drivers/media/video/gspca/ov534.c | |||
@@ -1533,16 +1533,4 @@ static struct usb_driver sd_driver = { | |||
1533 | #endif | 1533 | #endif |
1534 | }; | 1534 | }; |
1535 | 1535 | ||
1536 | /* -- module insert / remove -- */ | 1536 | module_usb_driver(sd_driver); |
1537 | static int __init sd_mod_init(void) | ||
1538 | { | ||
1539 | return usb_register(&sd_driver); | ||
1540 | } | ||
1541 | |||
1542 | static void __exit sd_mod_exit(void) | ||
1543 | { | ||
1544 | usb_deregister(&sd_driver); | ||
1545 | } | ||
1546 | |||
1547 | module_init(sd_mod_init); | ||
1548 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/ov534_9.c b/drivers/media/video/gspca/ov534_9.c index b3b1ea60a841..f30060d50633 100644 --- a/drivers/media/video/gspca/ov534_9.c +++ b/drivers/media/video/gspca/ov534_9.c | |||
@@ -1432,16 +1432,4 @@ static struct usb_driver sd_driver = { | |||
1432 | #endif | 1432 | #endif |
1433 | }; | 1433 | }; |
1434 | 1434 | ||
1435 | /* -- module insert / remove -- */ | 1435 | module_usb_driver(sd_driver); |
1436 | static int __init sd_mod_init(void) | ||
1437 | { | ||
1438 | return usb_register(&sd_driver); | ||
1439 | } | ||
1440 | |||
1441 | static void __exit sd_mod_exit(void) | ||
1442 | { | ||
1443 | usb_deregister(&sd_driver); | ||
1444 | } | ||
1445 | |||
1446 | module_init(sd_mod_init); | ||
1447 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/pac207.c b/drivers/media/video/gspca/pac207.c index 1600df152fd6..ece8b1e82a13 100644 --- a/drivers/media/video/gspca/pac207.c +++ b/drivers/media/video/gspca/pac207.c | |||
@@ -569,15 +569,4 @@ static struct usb_driver sd_driver = { | |||
569 | #endif | 569 | #endif |
570 | }; | 570 | }; |
571 | 571 | ||
572 | /* -- module insert / remove -- */ | 572 | module_usb_driver(sd_driver); |
573 | static int __init sd_mod_init(void) | ||
574 | { | ||
575 | return usb_register(&sd_driver); | ||
576 | } | ||
577 | static void __exit sd_mod_exit(void) | ||
578 | { | ||
579 | usb_deregister(&sd_driver); | ||
580 | } | ||
581 | |||
582 | module_init(sd_mod_init); | ||
583 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/pac7302.c b/drivers/media/video/gspca/pac7302.c index 1c44f78ff9e2..2811195258c4 100644 --- a/drivers/media/video/gspca/pac7302.c +++ b/drivers/media/video/gspca/pac7302.c | |||
@@ -1220,15 +1220,4 @@ static struct usb_driver sd_driver = { | |||
1220 | #endif | 1220 | #endif |
1221 | }; | 1221 | }; |
1222 | 1222 | ||
1223 | /* -- module insert / remove -- */ | 1223 | module_usb_driver(sd_driver); |
1224 | static int __init sd_mod_init(void) | ||
1225 | { | ||
1226 | return usb_register(&sd_driver); | ||
1227 | } | ||
1228 | static void __exit sd_mod_exit(void) | ||
1229 | { | ||
1230 | usb_deregister(&sd_driver); | ||
1231 | } | ||
1232 | |||
1233 | module_init(sd_mod_init); | ||
1234 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/pac7311.c b/drivers/media/video/gspca/pac7311.c index 7509d05dc065..1ac111176ffa 100644 --- a/drivers/media/video/gspca/pac7311.c +++ b/drivers/media/video/gspca/pac7311.c | |||
@@ -868,15 +868,4 @@ static struct usb_driver sd_driver = { | |||
868 | #endif | 868 | #endif |
869 | }; | 869 | }; |
870 | 870 | ||
871 | /* -- module insert / remove -- */ | 871 | module_usb_driver(sd_driver); |
872 | static int __init sd_mod_init(void) | ||
873 | { | ||
874 | return usb_register(&sd_driver); | ||
875 | } | ||
876 | static void __exit sd_mod_exit(void) | ||
877 | { | ||
878 | usb_deregister(&sd_driver); | ||
879 | } | ||
880 | |||
881 | module_init(sd_mod_init); | ||
882 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/se401.c b/drivers/media/video/gspca/se401.c index 3b71bbcd977a..1494e1829d36 100644 --- a/drivers/media/video/gspca/se401.c +++ b/drivers/media/video/gspca/se401.c | |||
@@ -766,15 +766,4 @@ static struct usb_driver sd_driver = { | |||
766 | .post_reset = sd_post_reset, | 766 | .post_reset = sd_post_reset, |
767 | }; | 767 | }; |
768 | 768 | ||
769 | /* -- module insert / remove -- */ | 769 | module_usb_driver(sd_driver); |
770 | static int __init sd_mod_init(void) | ||
771 | { | ||
772 | return usb_register(&sd_driver); | ||
773 | } | ||
774 | static void __exit sd_mod_exit(void) | ||
775 | { | ||
776 | usb_deregister(&sd_driver); | ||
777 | } | ||
778 | |||
779 | module_init(sd_mod_init); | ||
780 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/sn9c2028.c b/drivers/media/video/gspca/sn9c2028.c index 48aae3926a33..478533cb1152 100644 --- a/drivers/media/video/gspca/sn9c2028.c +++ b/drivers/media/video/gspca/sn9c2028.c | |||
@@ -737,16 +737,4 @@ static struct usb_driver sd_driver = { | |||
737 | #endif | 737 | #endif |
738 | }; | 738 | }; |
739 | 739 | ||
740 | /* -- module insert / remove -- */ | 740 | module_usb_driver(sd_driver); |
741 | static int __init sd_mod_init(void) | ||
742 | { | ||
743 | return usb_register(&sd_driver); | ||
744 | } | ||
745 | |||
746 | static void __exit sd_mod_exit(void) | ||
747 | { | ||
748 | usb_deregister(&sd_driver); | ||
749 | } | ||
750 | |||
751 | module_init(sd_mod_init); | ||
752 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/sn9c20x.c b/drivers/media/video/gspca/sn9c20x.c index 86e07a139a16..33cabc342dcf 100644 --- a/drivers/media/video/gspca/sn9c20x.c +++ b/drivers/media/video/gspca/sn9c20x.c | |||
@@ -2554,15 +2554,4 @@ static struct usb_driver sd_driver = { | |||
2554 | #endif | 2554 | #endif |
2555 | }; | 2555 | }; |
2556 | 2556 | ||
2557 | /* -- module insert / remove -- */ | 2557 | module_usb_driver(sd_driver); |
2558 | static int __init sd_mod_init(void) | ||
2559 | { | ||
2560 | return usb_register(&sd_driver); | ||
2561 | } | ||
2562 | static void __exit sd_mod_exit(void) | ||
2563 | { | ||
2564 | usb_deregister(&sd_driver); | ||
2565 | } | ||
2566 | |||
2567 | module_init(sd_mod_init); | ||
2568 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/sonixb.c b/drivers/media/video/gspca/sonixb.c index 146b459b08d5..ddb392dc4f2d 100644 --- a/drivers/media/video/gspca/sonixb.c +++ b/drivers/media/video/gspca/sonixb.c | |||
@@ -1527,15 +1527,4 @@ static struct usb_driver sd_driver = { | |||
1527 | #endif | 1527 | #endif |
1528 | }; | 1528 | }; |
1529 | 1529 | ||
1530 | /* -- module insert / remove -- */ | 1530 | module_usb_driver(sd_driver); |
1531 | static int __init sd_mod_init(void) | ||
1532 | { | ||
1533 | return usb_register(&sd_driver); | ||
1534 | } | ||
1535 | static void __exit sd_mod_exit(void) | ||
1536 | { | ||
1537 | usb_deregister(&sd_driver); | ||
1538 | } | ||
1539 | |||
1540 | module_init(sd_mod_init); | ||
1541 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/sonixj.c b/drivers/media/video/gspca/sonixj.c index c746bf19ca14..afa3186b8038 100644 --- a/drivers/media/video/gspca/sonixj.c +++ b/drivers/media/video/gspca/sonixj.c | |||
@@ -3104,15 +3104,4 @@ static struct usb_driver sd_driver = { | |||
3104 | #endif | 3104 | #endif |
3105 | }; | 3105 | }; |
3106 | 3106 | ||
3107 | /* -- module insert / remove -- */ | 3107 | module_usb_driver(sd_driver); |
3108 | static int __init sd_mod_init(void) | ||
3109 | { | ||
3110 | return usb_register(&sd_driver); | ||
3111 | } | ||
3112 | static void __exit sd_mod_exit(void) | ||
3113 | { | ||
3114 | usb_deregister(&sd_driver); | ||
3115 | } | ||
3116 | |||
3117 | module_init(sd_mod_init); | ||
3118 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/spca1528.c b/drivers/media/video/gspca/spca1528.c index 695673106e76..070b9c33b517 100644 --- a/drivers/media/video/gspca/spca1528.c +++ b/drivers/media/video/gspca/spca1528.c | |||
@@ -590,15 +590,4 @@ static struct usb_driver sd_driver = { | |||
590 | #endif | 590 | #endif |
591 | }; | 591 | }; |
592 | 592 | ||
593 | /* -- module insert / remove -- */ | 593 | module_usb_driver(sd_driver); |
594 | static int __init sd_mod_init(void) | ||
595 | { | ||
596 | return usb_register(&sd_driver); | ||
597 | } | ||
598 | static void __exit sd_mod_exit(void) | ||
599 | { | ||
600 | usb_deregister(&sd_driver); | ||
601 | } | ||
602 | |||
603 | module_init(sd_mod_init); | ||
604 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/spca500.c b/drivers/media/video/gspca/spca500.c index bb82c94ece14..103984708c77 100644 --- a/drivers/media/video/gspca/spca500.c +++ b/drivers/media/video/gspca/spca500.c | |||
@@ -1092,15 +1092,4 @@ static struct usb_driver sd_driver = { | |||
1092 | #endif | 1092 | #endif |
1093 | }; | 1093 | }; |
1094 | 1094 | ||
1095 | /* -- module insert / remove -- */ | 1095 | module_usb_driver(sd_driver); |
1096 | static int __init sd_mod_init(void) | ||
1097 | { | ||
1098 | return usb_register(&sd_driver); | ||
1099 | } | ||
1100 | static void __exit sd_mod_exit(void) | ||
1101 | { | ||
1102 | usb_deregister(&sd_driver); | ||
1103 | } | ||
1104 | |||
1105 | module_init(sd_mod_init); | ||
1106 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/spca501.c b/drivers/media/video/gspca/spca501.c index 7aaac72aee91..9c16821addd4 100644 --- a/drivers/media/video/gspca/spca501.c +++ b/drivers/media/video/gspca/spca501.c | |||
@@ -2188,15 +2188,4 @@ static struct usb_driver sd_driver = { | |||
2188 | #endif | 2188 | #endif |
2189 | }; | 2189 | }; |
2190 | 2190 | ||
2191 | /* -- module insert / remove -- */ | 2191 | module_usb_driver(sd_driver); |
2192 | static int __init sd_mod_init(void) | ||
2193 | { | ||
2194 | return usb_register(&sd_driver); | ||
2195 | } | ||
2196 | static void __exit sd_mod_exit(void) | ||
2197 | { | ||
2198 | usb_deregister(&sd_driver); | ||
2199 | } | ||
2200 | |||
2201 | module_init(sd_mod_init); | ||
2202 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/spca505.c b/drivers/media/video/gspca/spca505.c index 16722dc60394..1320f35e39f2 100644 --- a/drivers/media/video/gspca/spca505.c +++ b/drivers/media/video/gspca/spca505.c | |||
@@ -815,15 +815,4 @@ static struct usb_driver sd_driver = { | |||
815 | #endif | 815 | #endif |
816 | }; | 816 | }; |
817 | 817 | ||
818 | /* -- module insert / remove -- */ | 818 | module_usb_driver(sd_driver); |
819 | static int __init sd_mod_init(void) | ||
820 | { | ||
821 | return usb_register(&sd_driver); | ||
822 | } | ||
823 | static void __exit sd_mod_exit(void) | ||
824 | { | ||
825 | usb_deregister(&sd_driver); | ||
826 | } | ||
827 | |||
828 | module_init(sd_mod_init); | ||
829 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/spca506.c b/drivers/media/video/gspca/spca506.c index 89fec4c500af..54eed87672d2 100644 --- a/drivers/media/video/gspca/spca506.c +++ b/drivers/media/video/gspca/spca506.c | |||
@@ -714,21 +714,4 @@ static struct usb_driver sd_driver = { | |||
714 | #endif | 714 | #endif |
715 | }; | 715 | }; |
716 | 716 | ||
717 | /* -- module insert / remove -- */ | 717 | module_usb_driver(sd_driver); |
718 | static int __init sd_mod_init(void) | ||
719 | { | ||
720 | int ret; | ||
721 | ret = usb_register(&sd_driver); | ||
722 | if (ret < 0) | ||
723 | return ret; | ||
724 | PDEBUG(D_PROBE, "registered"); | ||
725 | return 0; | ||
726 | } | ||
727 | static void __exit sd_mod_exit(void) | ||
728 | { | ||
729 | usb_deregister(&sd_driver); | ||
730 | PDEBUG(D_PROBE, "deregistered"); | ||
731 | } | ||
732 | |||
733 | module_init(sd_mod_init); | ||
734 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/spca508.c b/drivers/media/video/gspca/spca508.c index a44fe3d25965..df4e16996461 100644 --- a/drivers/media/video/gspca/spca508.c +++ b/drivers/media/video/gspca/spca508.c | |||
@@ -1544,15 +1544,4 @@ static struct usb_driver sd_driver = { | |||
1544 | #endif | 1544 | #endif |
1545 | }; | 1545 | }; |
1546 | 1546 | ||
1547 | /* -- module insert / remove -- */ | 1547 | module_usb_driver(sd_driver); |
1548 | static int __init sd_mod_init(void) | ||
1549 | { | ||
1550 | return usb_register(&sd_driver); | ||
1551 | } | ||
1552 | static void __exit sd_mod_exit(void) | ||
1553 | { | ||
1554 | usb_deregister(&sd_driver); | ||
1555 | } | ||
1556 | |||
1557 | module_init(sd_mod_init); | ||
1558 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/spca561.c b/drivers/media/video/gspca/spca561.c index c82fd53cef95..259a0c73c664 100644 --- a/drivers/media/video/gspca/spca561.c +++ b/drivers/media/video/gspca/spca561.c | |||
@@ -1106,15 +1106,4 @@ static struct usb_driver sd_driver = { | |||
1106 | #endif | 1106 | #endif |
1107 | }; | 1107 | }; |
1108 | 1108 | ||
1109 | /* -- module insert / remove -- */ | 1109 | module_usb_driver(sd_driver); |
1110 | static int __init sd_mod_init(void) | ||
1111 | { | ||
1112 | return usb_register(&sd_driver); | ||
1113 | } | ||
1114 | static void __exit sd_mod_exit(void) | ||
1115 | { | ||
1116 | usb_deregister(&sd_driver); | ||
1117 | } | ||
1118 | |||
1119 | module_init(sd_mod_init); | ||
1120 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/sq905.c b/drivers/media/video/gspca/sq905.c index df805f798282..2fe3c29bd6b7 100644 --- a/drivers/media/video/gspca/sq905.c +++ b/drivers/media/video/gspca/sq905.c | |||
@@ -432,16 +432,4 @@ static struct usb_driver sd_driver = { | |||
432 | #endif | 432 | #endif |
433 | }; | 433 | }; |
434 | 434 | ||
435 | /* -- module insert / remove -- */ | 435 | module_usb_driver(sd_driver); |
436 | static int __init sd_mod_init(void) | ||
437 | { | ||
438 | return usb_register(&sd_driver); | ||
439 | } | ||
440 | |||
441 | static void __exit sd_mod_exit(void) | ||
442 | { | ||
443 | usb_deregister(&sd_driver); | ||
444 | } | ||
445 | |||
446 | module_init(sd_mod_init); | ||
447 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/sq905c.c b/drivers/media/video/gspca/sq905c.c index c2c056056e08..ae783634712f 100644 --- a/drivers/media/video/gspca/sq905c.c +++ b/drivers/media/video/gspca/sq905c.c | |||
@@ -339,16 +339,4 @@ static struct usb_driver sd_driver = { | |||
339 | #endif | 339 | #endif |
340 | }; | 340 | }; |
341 | 341 | ||
342 | /* -- module insert / remove -- */ | 342 | module_usb_driver(sd_driver); |
343 | static int __init sd_mod_init(void) | ||
344 | { | ||
345 | return usb_register(&sd_driver); | ||
346 | } | ||
347 | |||
348 | static void __exit sd_mod_exit(void) | ||
349 | { | ||
350 | usb_deregister(&sd_driver); | ||
351 | } | ||
352 | |||
353 | module_init(sd_mod_init); | ||
354 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/sq930x.c b/drivers/media/video/gspca/sq930x.c index e4255b4905e7..1a8ba9b3550a 100644 --- a/drivers/media/video/gspca/sq930x.c +++ b/drivers/media/video/gspca/sq930x.c | |||
@@ -1197,15 +1197,4 @@ static struct usb_driver sd_driver = { | |||
1197 | #endif | 1197 | #endif |
1198 | }; | 1198 | }; |
1199 | 1199 | ||
1200 | /* -- module insert / remove -- */ | 1200 | module_usb_driver(sd_driver); |
1201 | static int __init sd_mod_init(void) | ||
1202 | { | ||
1203 | return usb_register(&sd_driver); | ||
1204 | } | ||
1205 | static void __exit sd_mod_exit(void) | ||
1206 | { | ||
1207 | usb_deregister(&sd_driver); | ||
1208 | } | ||
1209 | |||
1210 | module_init(sd_mod_init); | ||
1211 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/stk014.c b/drivers/media/video/gspca/stk014.c index 42a7a28a6c8b..4ae7cc8f463a 100644 --- a/drivers/media/video/gspca/stk014.c +++ b/drivers/media/video/gspca/stk014.c | |||
@@ -519,15 +519,4 @@ static struct usb_driver sd_driver = { | |||
519 | #endif | 519 | #endif |
520 | }; | 520 | }; |
521 | 521 | ||
522 | /* -- module insert / remove -- */ | 522 | module_usb_driver(sd_driver); |
523 | static int __init sd_mod_init(void) | ||
524 | { | ||
525 | return usb_register(&sd_driver); | ||
526 | } | ||
527 | static void __exit sd_mod_exit(void) | ||
528 | { | ||
529 | usb_deregister(&sd_driver); | ||
530 | } | ||
531 | |||
532 | module_init(sd_mod_init); | ||
533 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/stv0680.c b/drivers/media/video/gspca/stv0680.c index 4dcc7e37f9fd..461ed645f309 100644 --- a/drivers/media/video/gspca/stv0680.c +++ b/drivers/media/video/gspca/stv0680.c | |||
@@ -355,15 +355,4 @@ static struct usb_driver sd_driver = { | |||
355 | #endif | 355 | #endif |
356 | }; | 356 | }; |
357 | 357 | ||
358 | /* -- module insert / remove -- */ | 358 | module_usb_driver(sd_driver); |
359 | static int __init sd_mod_init(void) | ||
360 | { | ||
361 | return usb_register(&sd_driver); | ||
362 | } | ||
363 | static void __exit sd_mod_exit(void) | ||
364 | { | ||
365 | usb_deregister(&sd_driver); | ||
366 | } | ||
367 | |||
368 | module_init(sd_mod_init); | ||
369 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/stv06xx/stv06xx.c b/drivers/media/video/gspca/stv06xx/stv06xx.c index b1fca7db1015..0ab425fbea9a 100644 --- a/drivers/media/video/gspca/stv06xx/stv06xx.c +++ b/drivers/media/video/gspca/stv06xx/stv06xx.c | |||
@@ -612,18 +612,7 @@ static struct usb_driver sd_driver = { | |||
612 | #endif | 612 | #endif |
613 | }; | 613 | }; |
614 | 614 | ||
615 | /* -- module insert / remove -- */ | 615 | module_usb_driver(sd_driver); |
616 | static int __init sd_mod_init(void) | ||
617 | { | ||
618 | return usb_register(&sd_driver); | ||
619 | } | ||
620 | static void __exit sd_mod_exit(void) | ||
621 | { | ||
622 | usb_deregister(&sd_driver); | ||
623 | } | ||
624 | |||
625 | module_init(sd_mod_init); | ||
626 | module_exit(sd_mod_exit); | ||
627 | 616 | ||
628 | module_param(dump_bridge, bool, S_IRUGO | S_IWUSR); | 617 | module_param(dump_bridge, bool, S_IRUGO | S_IWUSR); |
629 | MODULE_PARM_DESC(dump_bridge, "Dumps all usb bridge registers at startup"); | 618 | MODULE_PARM_DESC(dump_bridge, "Dumps all usb bridge registers at startup"); |
diff --git a/drivers/media/video/gspca/sunplus.c b/drivers/media/video/gspca/sunplus.c index c8909772435a..c80f0c0c75b6 100644 --- a/drivers/media/video/gspca/sunplus.c +++ b/drivers/media/video/gspca/sunplus.c | |||
@@ -1211,15 +1211,4 @@ static struct usb_driver sd_driver = { | |||
1211 | #endif | 1211 | #endif |
1212 | }; | 1212 | }; |
1213 | 1213 | ||
1214 | /* -- module insert / remove -- */ | 1214 | module_usb_driver(sd_driver); |
1215 | static int __init sd_mod_init(void) | ||
1216 | { | ||
1217 | return usb_register(&sd_driver); | ||
1218 | } | ||
1219 | static void __exit sd_mod_exit(void) | ||
1220 | { | ||
1221 | usb_deregister(&sd_driver); | ||
1222 | } | ||
1223 | |||
1224 | module_init(sd_mod_init); | ||
1225 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/t613.c b/drivers/media/video/gspca/t613.c index 90f0877eb599..ea44deb66af4 100644 --- a/drivers/media/video/gspca/t613.c +++ b/drivers/media/video/gspca/t613.c | |||
@@ -1438,15 +1438,4 @@ static struct usb_driver sd_driver = { | |||
1438 | #endif | 1438 | #endif |
1439 | }; | 1439 | }; |
1440 | 1440 | ||
1441 | /* -- module insert / remove -- */ | 1441 | module_usb_driver(sd_driver); |
1442 | static int __init sd_mod_init(void) | ||
1443 | { | ||
1444 | return usb_register(&sd_driver); | ||
1445 | } | ||
1446 | static void __exit sd_mod_exit(void) | ||
1447 | { | ||
1448 | usb_deregister(&sd_driver); | ||
1449 | } | ||
1450 | |||
1451 | module_init(sd_mod_init); | ||
1452 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/topro.c b/drivers/media/video/gspca/topro.c index 29596c59837f..b2695b1dc603 100644 --- a/drivers/media/video/gspca/topro.c +++ b/drivers/media/video/gspca/topro.c | |||
@@ -4971,18 +4971,7 @@ static struct usb_driver sd_driver = { | |||
4971 | #endif | 4971 | #endif |
4972 | }; | 4972 | }; |
4973 | 4973 | ||
4974 | /* -- module insert / remove -- */ | 4974 | module_usb_driver(sd_driver); |
4975 | static int __init sd_mod_init(void) | ||
4976 | { | ||
4977 | return usb_register(&sd_driver); | ||
4978 | } | ||
4979 | static void __exit sd_mod_exit(void) | ||
4980 | { | ||
4981 | usb_deregister(&sd_driver); | ||
4982 | } | ||
4983 | |||
4984 | module_init(sd_mod_init); | ||
4985 | module_exit(sd_mod_exit); | ||
4986 | 4975 | ||
4987 | module_param(force_sensor, int, 0644); | 4976 | module_param(force_sensor, int, 0644); |
4988 | MODULE_PARM_DESC(force_sensor, | 4977 | MODULE_PARM_DESC(force_sensor, |
diff --git a/drivers/media/video/gspca/tv8532.c b/drivers/media/video/gspca/tv8532.c index 933ef2ca658c..c8922c5ffbf5 100644 --- a/drivers/media/video/gspca/tv8532.c +++ b/drivers/media/video/gspca/tv8532.c | |||
@@ -418,16 +418,4 @@ static struct usb_driver sd_driver = { | |||
418 | #endif | 418 | #endif |
419 | }; | 419 | }; |
420 | 420 | ||
421 | /* -- module insert / remove -- */ | 421 | module_usb_driver(sd_driver); |
422 | static int __init sd_mod_init(void) | ||
423 | { | ||
424 | return usb_register(&sd_driver); | ||
425 | } | ||
426 | |||
427 | static void __exit sd_mod_exit(void) | ||
428 | { | ||
429 | usb_deregister(&sd_driver); | ||
430 | } | ||
431 | |||
432 | module_init(sd_mod_init); | ||
433 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/vc032x.c b/drivers/media/video/gspca/vc032x.c index 7ee2c8271dcc..208f6b2d512a 100644 --- a/drivers/media/video/gspca/vc032x.c +++ b/drivers/media/video/gspca/vc032x.c | |||
@@ -4230,15 +4230,4 @@ static struct usb_driver sd_driver = { | |||
4230 | #endif | 4230 | #endif |
4231 | }; | 4231 | }; |
4232 | 4232 | ||
4233 | /* -- module insert / remove -- */ | 4233 | module_usb_driver(sd_driver); |
4234 | static int __init sd_mod_init(void) | ||
4235 | { | ||
4236 | return usb_register(&sd_driver); | ||
4237 | } | ||
4238 | static void __exit sd_mod_exit(void) | ||
4239 | { | ||
4240 | usb_deregister(&sd_driver); | ||
4241 | } | ||
4242 | |||
4243 | module_init(sd_mod_init); | ||
4244 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/vicam.c b/drivers/media/video/gspca/vicam.c index 81dd4c99d025..d12ea1518ace 100644 --- a/drivers/media/video/gspca/vicam.c +++ b/drivers/media/video/gspca/vicam.c | |||
@@ -368,16 +368,4 @@ static struct usb_driver sd_driver = { | |||
368 | #endif | 368 | #endif |
369 | }; | 369 | }; |
370 | 370 | ||
371 | /* -- module insert / remove -- */ | 371 | module_usb_driver(sd_driver); |
372 | static int __init sd_mod_init(void) | ||
373 | { | ||
374 | return usb_register(&sd_driver); | ||
375 | } | ||
376 | |||
377 | static void __exit sd_mod_exit(void) | ||
378 | { | ||
379 | usb_deregister(&sd_driver); | ||
380 | } | ||
381 | |||
382 | module_init(sd_mod_init); | ||
383 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/xirlink_cit.c b/drivers/media/video/gspca/xirlink_cit.c index 3aed42acdb5a..fbb6ed25ec31 100644 --- a/drivers/media/video/gspca/xirlink_cit.c +++ b/drivers/media/video/gspca/xirlink_cit.c | |||
@@ -3325,15 +3325,4 @@ static struct usb_driver sd_driver = { | |||
3325 | #endif | 3325 | #endif |
3326 | }; | 3326 | }; |
3327 | 3327 | ||
3328 | /* -- module insert / remove -- */ | 3328 | module_usb_driver(sd_driver); |
3329 | static int __init sd_mod_init(void) | ||
3330 | { | ||
3331 | return usb_register(&sd_driver); | ||
3332 | } | ||
3333 | static void __exit sd_mod_exit(void) | ||
3334 | { | ||
3335 | usb_deregister(&sd_driver); | ||
3336 | } | ||
3337 | |||
3338 | module_init(sd_mod_init); | ||
3339 | module_exit(sd_mod_exit); | ||
diff --git a/drivers/media/video/gspca/zc3xx.c b/drivers/media/video/gspca/zc3xx.c index 30ea1e479492..0202fead6b97 100644 --- a/drivers/media/video/gspca/zc3xx.c +++ b/drivers/media/video/gspca/zc3xx.c | |||
@@ -7050,18 +7050,7 @@ static struct usb_driver sd_driver = { | |||
7050 | #endif | 7050 | #endif |
7051 | }; | 7051 | }; |
7052 | 7052 | ||
7053 | static int __init sd_mod_init(void) | 7053 | module_usb_driver(sd_driver); |
7054 | { | ||
7055 | return usb_register(&sd_driver); | ||
7056 | } | ||
7057 | |||
7058 | static void __exit sd_mod_exit(void) | ||
7059 | { | ||
7060 | usb_deregister(&sd_driver); | ||
7061 | } | ||
7062 | |||
7063 | module_init(sd_mod_init); | ||
7064 | module_exit(sd_mod_exit); | ||
7065 | 7054 | ||
7066 | module_param(force_sensor, int, 0644); | 7055 | module_param(force_sensor, int, 0644); |
7067 | MODULE_PARM_DESC(force_sensor, | 7056 | MODULE_PARM_DESC(force_sensor, |
diff --git a/drivers/media/video/hdpvr/hdpvr-core.c b/drivers/media/video/hdpvr/hdpvr-core.c index 441dacf642bb..3f1a5b1beeba 100644 --- a/drivers/media/video/hdpvr/hdpvr-core.c +++ b/drivers/media/video/hdpvr/hdpvr-core.c | |||
@@ -452,26 +452,7 @@ static struct usb_driver hdpvr_usb_driver = { | |||
452 | .id_table = hdpvr_table, | 452 | .id_table = hdpvr_table, |
453 | }; | 453 | }; |
454 | 454 | ||
455 | static int __init hdpvr_init(void) | 455 | module_usb_driver(hdpvr_usb_driver); |
456 | { | ||
457 | int result; | ||
458 | |||
459 | /* register this driver with the USB subsystem */ | ||
460 | result = usb_register(&hdpvr_usb_driver); | ||
461 | if (result) | ||
462 | err("usb_register failed. Error number %d", result); | ||
463 | |||
464 | return result; | ||
465 | } | ||
466 | |||
467 | static void __exit hdpvr_exit(void) | ||
468 | { | ||
469 | /* deregister this driver with the USB subsystem */ | ||
470 | usb_deregister(&hdpvr_usb_driver); | ||
471 | } | ||
472 | |||
473 | module_init(hdpvr_init); | ||
474 | module_exit(hdpvr_exit); | ||
475 | 456 | ||
476 | MODULE_LICENSE("GPL"); | 457 | MODULE_LICENSE("GPL"); |
477 | MODULE_VERSION("0.2.1"); | 458 | MODULE_VERSION("0.2.1"); |
diff --git a/drivers/media/video/s2255drv.c b/drivers/media/video/s2255drv.c index 803c9c82e496..c1bef6187661 100644 --- a/drivers/media/video/s2255drv.c +++ b/drivers/media/video/s2255drv.c | |||
@@ -2682,25 +2682,7 @@ static struct usb_driver s2255_driver = { | |||
2682 | .id_table = s2255_table, | 2682 | .id_table = s2255_table, |
2683 | }; | 2683 | }; |
2684 | 2684 | ||
2685 | static int __init usb_s2255_init(void) | 2685 | module_usb_driver(s2255_driver); |
2686 | { | ||
2687 | int result; | ||
2688 | /* register this driver with the USB subsystem */ | ||
2689 | result = usb_register(&s2255_driver); | ||
2690 | if (result) | ||
2691 | pr_err(KBUILD_MODNAME | ||
2692 | ": usb_register failed. Error number %d\n", result); | ||
2693 | dprintk(2, "%s\n", __func__); | ||
2694 | return result; | ||
2695 | } | ||
2696 | |||
2697 | static void __exit usb_s2255_exit(void) | ||
2698 | { | ||
2699 | usb_deregister(&s2255_driver); | ||
2700 | } | ||
2701 | |||
2702 | module_init(usb_s2255_init); | ||
2703 | module_exit(usb_s2255_exit); | ||
2704 | 2686 | ||
2705 | MODULE_DESCRIPTION("Sensoray 2255 Video for Linux driver"); | 2687 | MODULE_DESCRIPTION("Sensoray 2255 Video for Linux driver"); |
2706 | MODULE_AUTHOR("Dean Anderson (Sensoray Company Inc.)"); | 2688 | MODULE_AUTHOR("Dean Anderson (Sensoray Company Inc.)"); |
diff --git a/drivers/media/video/sn9c102/sn9c102_core.c b/drivers/media/video/sn9c102/sn9c102_core.c index 16cb07c5c27b..7025be129286 100644 --- a/drivers/media/video/sn9c102/sn9c102_core.c +++ b/drivers/media/video/sn9c102/sn9c102_core.c | |||
@@ -3420,27 +3420,4 @@ static struct usb_driver sn9c102_usb_driver = { | |||
3420 | .disconnect = sn9c102_usb_disconnect, | 3420 | .disconnect = sn9c102_usb_disconnect, |
3421 | }; | 3421 | }; |
3422 | 3422 | ||
3423 | /*****************************************************************************/ | 3423 | module_usb_driver(sn9c102_usb_driver); |
3424 | |||
3425 | static int __init sn9c102_module_init(void) | ||
3426 | { | ||
3427 | int err = 0; | ||
3428 | |||
3429 | KDBG(2, SN9C102_MODULE_NAME " v" SN9C102_MODULE_VERSION); | ||
3430 | KDBG(3, SN9C102_MODULE_AUTHOR); | ||
3431 | |||
3432 | if ((err = usb_register(&sn9c102_usb_driver))) | ||
3433 | KDBG(1, "usb_register() failed"); | ||
3434 | |||
3435 | return err; | ||
3436 | } | ||
3437 | |||
3438 | |||
3439 | static void __exit sn9c102_module_exit(void) | ||
3440 | { | ||
3441 | usb_deregister(&sn9c102_usb_driver); | ||
3442 | } | ||
3443 | |||
3444 | |||
3445 | module_init(sn9c102_module_init); | ||
3446 | module_exit(sn9c102_module_exit); | ||
diff --git a/drivers/media/video/stk-webcam.c b/drivers/media/video/stk-webcam.c index cbc105f975de..b7fb5a5cad7e 100644 --- a/drivers/media/video/stk-webcam.c +++ b/drivers/media/video/stk-webcam.c | |||
@@ -1377,25 +1377,4 @@ static struct usb_driver stk_camera_driver = { | |||
1377 | #endif | 1377 | #endif |
1378 | }; | 1378 | }; |
1379 | 1379 | ||
1380 | 1380 | module_usb_driver(stk_camera_driver); | |
1381 | static int __init stk_camera_init(void) | ||
1382 | { | ||
1383 | int result; | ||
1384 | |||
1385 | result = usb_register(&stk_camera_driver); | ||
1386 | if (result) | ||
1387 | STK_ERROR("usb_register failed ! Error number %d\n", result); | ||
1388 | |||
1389 | |||
1390 | return result; | ||
1391 | } | ||
1392 | |||
1393 | static void __exit stk_camera_exit(void) | ||
1394 | { | ||
1395 | usb_deregister(&stk_camera_driver); | ||
1396 | } | ||
1397 | |||
1398 | module_init(stk_camera_init); | ||
1399 | module_exit(stk_camera_exit); | ||
1400 | |||
1401 | |||
diff --git a/drivers/media/video/tm6000/tm6000-cards.c b/drivers/media/video/tm6000/tm6000-cards.c index ec2578a0fdf7..ff939bc0e0b9 100644 --- a/drivers/media/video/tm6000/tm6000-cards.c +++ b/drivers/media/video/tm6000/tm6000-cards.c | |||
@@ -1371,31 +1371,7 @@ static struct usb_driver tm6000_usb_driver = { | |||
1371 | .id_table = tm6000_id_table, | 1371 | .id_table = tm6000_id_table, |
1372 | }; | 1372 | }; |
1373 | 1373 | ||
1374 | static int __init tm6000_module_init(void) | 1374 | module_usb_driver(tm6000_usb_driver); |
1375 | { | ||
1376 | int result; | ||
1377 | |||
1378 | printk(KERN_INFO "tm6000" " v4l2 driver version %d.%d.%d loaded\n", | ||
1379 | (TM6000_VERSION >> 16) & 0xff, | ||
1380 | (TM6000_VERSION >> 8) & 0xff, TM6000_VERSION & 0xff); | ||
1381 | |||
1382 | /* register this driver with the USB subsystem */ | ||
1383 | result = usb_register(&tm6000_usb_driver); | ||
1384 | if (result) | ||
1385 | printk(KERN_ERR "tm6000" | ||
1386 | " usb_register failed. Error number %d.\n", result); | ||
1387 | |||
1388 | return result; | ||
1389 | } | ||
1390 | |||
1391 | static void __exit tm6000_module_exit(void) | ||
1392 | { | ||
1393 | /* deregister at USB subsystem */ | ||
1394 | usb_deregister(&tm6000_usb_driver); | ||
1395 | } | ||
1396 | |||
1397 | module_init(tm6000_module_init); | ||
1398 | module_exit(tm6000_module_exit); | ||
1399 | 1375 | ||
1400 | MODULE_DESCRIPTION("Trident TVMaster TM5600/TM6000/TM6010 USB2 adapter"); | 1376 | MODULE_DESCRIPTION("Trident TVMaster TM5600/TM6000/TM6010 USB2 adapter"); |
1401 | MODULE_AUTHOR("Mauro Carvalho Chehab"); | 1377 | MODULE_AUTHOR("Mauro Carvalho Chehab"); |
diff --git a/drivers/media/video/zr364xx.c b/drivers/media/video/zr364xx.c index e78cf94f491e..cd2e39fc4bf0 100644 --- a/drivers/media/video/zr364xx.c +++ b/drivers/media/video/zr364xx.c | |||
@@ -1695,28 +1695,7 @@ static struct usb_driver zr364xx_driver = { | |||
1695 | .id_table = device_table | 1695 | .id_table = device_table |
1696 | }; | 1696 | }; |
1697 | 1697 | ||
1698 | 1698 | module_usb_driver(zr364xx_driver); | |
1699 | static int __init zr364xx_init(void) | ||
1700 | { | ||
1701 | int retval; | ||
1702 | retval = usb_register(&zr364xx_driver); | ||
1703 | if (retval) | ||
1704 | printk(KERN_ERR KBUILD_MODNAME ": usb_register failed!\n"); | ||
1705 | else | ||
1706 | printk(KERN_INFO KBUILD_MODNAME ": " DRIVER_DESC "\n"); | ||
1707 | return retval; | ||
1708 | } | ||
1709 | |||
1710 | |||
1711 | static void __exit zr364xx_exit(void) | ||
1712 | { | ||
1713 | printk(KERN_INFO KBUILD_MODNAME ": " DRIVER_DESC " module unloaded\n"); | ||
1714 | usb_deregister(&zr364xx_driver); | ||
1715 | } | ||
1716 | |||
1717 | |||
1718 | module_init(zr364xx_init); | ||
1719 | module_exit(zr364xx_exit); | ||
1720 | 1699 | ||
1721 | MODULE_AUTHOR(DRIVER_AUTHOR); | 1700 | MODULE_AUTHOR(DRIVER_AUTHOR); |
1722 | MODULE_DESCRIPTION(DRIVER_DESC); | 1701 | MODULE_DESCRIPTION(DRIVER_DESC); |