aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/misc/adutux.c
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/misc/adutux.c
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/misc/adutux.c')
-rw-r--r--drivers/usb/misc/adutux.c35
1 files changed, 1 insertions, 34 deletions
diff --git a/drivers/usb/misc/adutux.c b/drivers/usb/misc/adutux.c
index fe858711651c..284b85461410 100644
--- a/drivers/usb/misc/adutux.c
+++ b/drivers/usb/misc/adutux.c
@@ -885,40 +885,7 @@ static struct usb_driver adu_driver = {
885 .id_table = device_table, 885 .id_table = device_table,
886}; 886};
887 887
888static int __init adu_init(void) 888module_usb_driver(adu_driver);
889{
890 int result;
891
892 dbg(2," %s : enter", __func__);
893
894 /* register this driver with the USB subsystem */
895 result = usb_register(&adu_driver);
896 if (result < 0) {
897 printk(KERN_ERR "usb_register failed for the "__FILE__
898 " driver. Error number %d\n", result);
899 goto exit;
900 }
901
902 printk(KERN_INFO "adutux " DRIVER_DESC " " DRIVER_VERSION "\n");
903 printk(KERN_INFO "adutux is an experimental driver. "
904 "Use at your own risk\n");
905
906exit:
907 dbg(2," %s : leave, return value %d", __func__, result);
908
909 return result;
910}
911
912static void __exit adu_exit(void)
913{
914 dbg(2," %s : enter", __func__);
915 /* deregister this driver with the USB subsystem */
916 usb_deregister(&adu_driver);
917 dbg(2," %s : leave", __func__);
918}
919
920module_init(adu_init);
921module_exit(adu_exit);
922 889
923MODULE_AUTHOR(DRIVER_AUTHOR); 890MODULE_AUTHOR(DRIVER_AUTHOR);
924MODULE_DESCRIPTION(DRIVER_DESC); 891MODULE_DESCRIPTION(DRIVER_DESC);