From ecb3b2b35db49778b6d89e3ffd0c400776c20735 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Fri, 18 Nov 2011 09:46:12 -0800 Subject: USB: convert drivers/media/* to use module_usb_driver() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Cc: Luca Risolia Cc: Jean-Francois Moine Cc: Frank Zago Cc: Olivier Lorin Cc: Erik Andren Cc: Hans de Goede Cc: Brian Johnson Cc: Leandro Costantino Cc: Antoine Jacquet Cc: Jarod Wilson Cc: Florian Mickler Cc: Antti Palosaari Cc: Michael Krufky Cc: "David Härdeman" Cc: Florent Audebert Cc: Sam Doshi Cc: Manu Abraham Cc: Olivier Grenie Cc: Patrick Boettcher Cc: "Igor M. Liplianin" Cc: Derek Kelly Cc: Malcolm Priestley Cc: Steven Toth Cc: "André Weidemann" Cc: Martin Wilks Cc: Tejun Heo Cc: Jose Alberto Reguero Cc: David Henningsson Cc: Paul Gortmaker Cc: Joe Perches Cc: Jesper Juhl Cc: Lucas De Marchi Cc: Hans Verkuil Cc: Alexey Khoroshilov Cc: Anssi Hannula Cc: Rafi Rubin Cc: Dan Carpenter Cc: Paul Bender Cc: Devin Heitmueller Cc: "Márcio A Alves" Cc: Julia Lawall Cc: Laurent Pinchart Cc: Chris Rankin Cc: Lee Jones Cc: Andy Walls Cc: Andrew Morton Cc: Mike Frysinger Cc: Dean Anderson Cc: Pete Eberlein Cc: Arvydas Sidorenko Cc: Andrea Anacleto Signed-off-by: Greg Kroah-Hartman --- drivers/media/dvb/dvb-usb/gp8psk.c | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) (limited to 'drivers/media/dvb/dvb-usb/gp8psk.c') diff --git a/drivers/media/dvb/dvb-usb/gp8psk.c b/drivers/media/dvb/dvb-usb/gp8psk.c index 5f71284703d..5d0384dd45b 100644 --- a/drivers/media/dvb/dvb-usb/gp8psk.c +++ b/drivers/media/dvb/dvb-usb/gp8psk.c @@ -320,26 +320,7 @@ static struct usb_driver gp8psk_usb_driver = { .id_table = gp8psk_usb_table, }; -/* module stuff */ -static int __init gp8psk_usb_module_init(void) -{ - int result; - if ((result = usb_register(&gp8psk_usb_driver))) { - err("usb_register failed. (%d)",result); - return result; - } - - return 0; -} - -static void __exit gp8psk_usb_module_exit(void) -{ - /* deregister this driver from the USB subsystem */ - usb_deregister(&gp8psk_usb_driver); -} - -module_init(gp8psk_usb_module_init); -module_exit(gp8psk_usb_module_exit); +module_usb_driver(gp8psk_usb_driver); MODULE_AUTHOR("Alan Nisota "); MODULE_DESCRIPTION("Driver for Genpix DVB-S"); -- cgit v1.2.3-70-g09d2