From d632eb1bf22e11def74e4e53cc47d790fbdba105 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Fri, 18 Nov 2011 09:44:20 -0800 Subject: USB: convert drivers/net/* to use module_usb_driver() This converts the drivers in drivers/net/* 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: Wolfgang Grandegger Cc: Samuel Ortiz Cc: Oliver Neukum Cc: Peter Korsgaard Cc: Petko Manolov Cc: Steve Glendinning Cc: Christian Lamparter Cc: "John W. Linville" Cc: Dan Williams Cc: Jussi Kivilinna Cc: Ivo van Doorn Cc: Gertjan van Wingerde Cc: Helmut Schaa Cc: Herton Ronaldo Krzesinski Cc: Hin-Tak Leung Cc: Larry Finger Cc: Chaoming Li Cc: Lucas De Marchi Cc: "David S. Miller" Cc: Roel Kluin Cc: Paul Gortmaker Cc: Jiri Pirko Cc: Pavel Roskin Cc: Yoann DI-RUZZA Cc: George Signed-off-by: Greg Kroah-Hartman --- drivers/net/wireless/libertas/if_usb.c | 24 +----------------------- 1 file changed, 1 insertion(+), 23 deletions(-) (limited to 'drivers/net/wireless/libertas/if_usb.c') diff --git a/drivers/net/wireless/libertas/if_usb.c b/drivers/net/wireless/libertas/if_usb.c index db879c364ebf..b5fbbc7947df 100644 --- a/drivers/net/wireless/libertas/if_usb.c +++ b/drivers/net/wireless/libertas/if_usb.c @@ -1184,29 +1184,7 @@ static struct usb_driver if_usb_driver = { .reset_resume = if_usb_resume, }; -static int __init if_usb_init_module(void) -{ - int ret = 0; - - lbs_deb_enter(LBS_DEB_MAIN); - - ret = usb_register(&if_usb_driver); - - lbs_deb_leave_args(LBS_DEB_MAIN, "ret %d", ret); - return ret; -} - -static void __exit if_usb_exit_module(void) -{ - lbs_deb_enter(LBS_DEB_MAIN); - - usb_deregister(&if_usb_driver); - - lbs_deb_leave(LBS_DEB_MAIN); -} - -module_init(if_usb_init_module); -module_exit(if_usb_exit_module); +module_usb_driver(if_usb_driver); MODULE_DESCRIPTION("8388 USB WLAN Driver"); MODULE_AUTHOR("Marvell International Ltd. and Red Hat, Inc."); -- cgit v1.2.3