Commit d9b1b787 authored by Johannes Hölzl's avatar Johannes Hölzl Committed by Greg Kroah-Hartman

USB serial: add driver pointer to all usb-serial drivers

Every usb serial driver should have a pointer to the corresponding usb driver.
So the usb serial core can add a new id not only to the usb serial driver, but
also to the usb driver.

Also the usb drivers of ark3116, mos7720 and mos7840 missed the flag
no_dynamic_id=1. This is added now.
Signed-off-by: default avatarJohannes Hölzl <johannes.hoelzl@gmx.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 93bacefc
...@@ -572,8 +572,17 @@ static void aircable_unthrottle(struct usb_serial_port *port) ...@@ -572,8 +572,17 @@ static void aircable_unthrottle(struct usb_serial_port *port)
schedule_work(&priv->rx_work); schedule_work(&priv->rx_work);
} }
static struct usb_driver aircable_driver = {
.name = "aircable",
.probe = usb_serial_probe,
.disconnect = usb_serial_disconnect,
.id_table = id_table,
.no_dynamic_id = 1,
};
static struct usb_serial_driver aircable_device = { static struct usb_serial_driver aircable_device = {
.description = "aircable", .description = "aircable",
.usb_driver = &aircable_driver,
.id_table = id_table, .id_table = id_table,
.num_ports = 1, .num_ports = 1,
.attach = aircable_attach, .attach = aircable_attach,
...@@ -587,13 +596,6 @@ static struct usb_serial_driver aircable_device = { ...@@ -587,13 +596,6 @@ static struct usb_serial_driver aircable_device = {
.unthrottle = aircable_unthrottle, .unthrottle = aircable_unthrottle,
}; };
static struct usb_driver aircable_driver = {
.name = "aircable",
.probe = usb_serial_probe,
.disconnect = usb_serial_disconnect,
.id_table = id_table,
};
static int __init aircable_init (void) static int __init aircable_init (void)
{ {
int retval; int retval;
......
...@@ -277,6 +277,7 @@ static struct usb_serial_driver airprime_device = { ...@@ -277,6 +277,7 @@ static struct usb_serial_driver airprime_device = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.name = "airprime", .name = "airprime",
}, },
.usb_driver = &airprime_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
......
...@@ -444,6 +444,7 @@ static struct usb_driver ark3116_driver = { ...@@ -444,6 +444,7 @@ static struct usb_driver ark3116_driver = {
.probe = usb_serial_probe, .probe = usb_serial_probe,
.disconnect = usb_serial_disconnect, .disconnect = usb_serial_disconnect,
.id_table = id_table, .id_table = id_table,
.no_dynamic_id = 1,
}; };
static struct usb_serial_driver ark3116_device = { static struct usb_serial_driver ark3116_device = {
...@@ -452,6 +453,7 @@ static struct usb_serial_driver ark3116_device = { ...@@ -452,6 +453,7 @@ static struct usb_serial_driver ark3116_device = {
.name = "ark3116", .name = "ark3116",
}, },
.id_table = id_table, .id_table = id_table,
.usb_driver = &ark3116_driver,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
.num_bulk_out = 1, .num_bulk_out = 1,
......
...@@ -126,6 +126,7 @@ static struct usb_serial_driver belkin_device = { ...@@ -126,6 +126,7 @@ static struct usb_serial_driver belkin_device = {
.name = "belkin", .name = "belkin",
}, },
.description = "Belkin / Peracom / GoHubs USB Serial Adapter", .description = "Belkin / Peracom / GoHubs USB Serial Adapter",
.usb_driver = &belkin_driver,
.id_table = id_table_combined, .id_table = id_table_combined,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -89,6 +89,7 @@ static struct usb_serial_driver cp2101_device = { ...@@ -89,6 +89,7 @@ static struct usb_serial_driver cp2101_device = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.name = "cp2101", .name = "cp2101",
}, },
.usb_driver = &cp2101_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = 0, .num_interrupt_in = 0,
.num_bulk_in = 0, .num_bulk_in = 0,
......
...@@ -88,6 +88,7 @@ static struct usb_serial_driver cyberjack_device = { ...@@ -88,6 +88,7 @@ static struct usb_serial_driver cyberjack_device = {
.name = "cyberjack", .name = "cyberjack",
}, },
.description = "Reiner SCT Cyberjack USB card reader", .description = "Reiner SCT Cyberjack USB card reader",
.usb_driver = &cyberjack_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -193,6 +193,7 @@ static struct usb_serial_driver cypress_earthmate_device = { ...@@ -193,6 +193,7 @@ static struct usb_serial_driver cypress_earthmate_device = {
.name = "earthmate", .name = "earthmate",
}, },
.description = "DeLorme Earthmate USB", .description = "DeLorme Earthmate USB",
.usb_driver = &cypress_driver,
.id_table = id_table_earthmate, .id_table = id_table_earthmate,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_interrupt_out = 1, .num_interrupt_out = 1,
...@@ -222,6 +223,7 @@ static struct usb_serial_driver cypress_hidcom_device = { ...@@ -222,6 +223,7 @@ static struct usb_serial_driver cypress_hidcom_device = {
.name = "cyphidcom", .name = "cyphidcom",
}, },
.description = "HID->COM RS232 Adapter", .description = "HID->COM RS232 Adapter",
.usb_driver = &cypress_driver,
.id_table = id_table_cyphidcomrs232, .id_table = id_table_cyphidcomrs232,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_interrupt_out = 1, .num_interrupt_out = 1,
...@@ -251,6 +253,7 @@ static struct usb_serial_driver cypress_ca42v2_device = { ...@@ -251,6 +253,7 @@ static struct usb_serial_driver cypress_ca42v2_device = {
.name = "nokiaca42v2", .name = "nokiaca42v2",
}, },
.description = "Nokia CA-42 V2 Adapter", .description = "Nokia CA-42 V2 Adapter",
.usb_driver = &cypress_driver,
.id_table = id_table_nokiaca42v2, .id_table = id_table_nokiaca42v2,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_interrupt_out = 1, .num_interrupt_out = 1,
......
...@@ -509,6 +509,7 @@ static struct usb_serial_driver digi_acceleport_2_device = { ...@@ -509,6 +509,7 @@ static struct usb_serial_driver digi_acceleport_2_device = {
.name = "digi_2", .name = "digi_2",
}, },
.description = "Digi 2 port USB adapter", .description = "Digi 2 port USB adapter",
.usb_driver = &digi_driver,
.id_table = id_table_2, .id_table = id_table_2,
.num_interrupt_in = 0, .num_interrupt_in = 0,
.num_bulk_in = 4, .num_bulk_in = 4,
...@@ -538,6 +539,7 @@ static struct usb_serial_driver digi_acceleport_4_device = { ...@@ -538,6 +539,7 @@ static struct usb_serial_driver digi_acceleport_4_device = {
.name = "digi_4", .name = "digi_4",
}, },
.description = "Digi 4 port USB adapter", .description = "Digi 4 port USB adapter",
.usb_driver = &digi_driver,
.id_table = id_table_4, .id_table = id_table_4,
.num_interrupt_in = 0, .num_interrupt_in = 0,
.num_bulk_in = 5, .num_bulk_in = 5,
......
...@@ -117,6 +117,7 @@ static struct usb_serial_driver empeg_device = { ...@@ -117,6 +117,7 @@ static struct usb_serial_driver empeg_device = {
.name = "empeg", .name = "empeg",
}, },
.id_table = id_table, .id_table = id_table,
.usb_driver = &empeg_driver,
.num_interrupt_in = 0, .num_interrupt_in = 0,
.num_bulk_in = 1, .num_bulk_in = 1,
.num_bulk_out = 1, .num_bulk_out = 1,
......
...@@ -615,6 +615,7 @@ static struct usb_serial_driver ftdi_sio_device = { ...@@ -615,6 +615,7 @@ static struct usb_serial_driver ftdi_sio_device = {
.name = "ftdi_sio", .name = "ftdi_sio",
}, },
.description = "FTDI USB Serial Device", .description = "FTDI USB Serial Device",
.usb_driver = &ftdi_driver ,
.id_table = id_table_combined, .id_table = id_table_combined,
.num_interrupt_in = 0, .num_interrupt_in = 0,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -58,6 +58,7 @@ static struct usb_serial_driver funsoft_device = { ...@@ -58,6 +58,7 @@ static struct usb_serial_driver funsoft_device = {
.name = "funsoft", .name = "funsoft",
}, },
.id_table = id_table, .id_table = id_table,
.usb_driver = &funsoft_driver,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
.num_bulk_out = NUM_DONT_CARE, .num_bulk_out = NUM_DONT_CARE,
......
...@@ -1566,6 +1566,7 @@ static struct usb_serial_driver garmin_device = { ...@@ -1566,6 +1566,7 @@ static struct usb_serial_driver garmin_device = {
.name = "garmin_gps", .name = "garmin_gps",
}, },
.description = "Garmin GPS usb/tty", .description = "Garmin GPS usb/tty",
.usb_driver = &garmin_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -20,6 +20,10 @@ ...@@ -20,6 +20,10 @@
#include <linux/usb/serial.h> #include <linux/usb/serial.h>
#include <asm/uaccess.h> #include <asm/uaccess.h>
static int generic_probe(struct usb_interface *interface,
const struct usb_device_id *id);
static int debug; static int debug;
#ifdef CONFIG_USB_SERIAL_GENERIC #ifdef CONFIG_USB_SERIAL_GENERIC
...@@ -34,6 +38,21 @@ MODULE_PARM_DESC(product, "User specified USB idProduct"); ...@@ -34,6 +38,21 @@ MODULE_PARM_DESC(product, "User specified USB idProduct");
static struct usb_device_id generic_device_ids[2]; /* Initially all zeroes. */ static struct usb_device_id generic_device_ids[2]; /* Initially all zeroes. */
/* we want to look at all devices, as the vendor/product id can change
* depending on the command line argument */
static struct usb_device_id generic_serial_ids[] = {
{.driver_info = 42},
{}
};
static struct usb_driver generic_driver = {
.name = "usbserial_generic",
.probe = generic_probe,
.disconnect = usb_serial_disconnect,
.id_table = generic_serial_ids,
.no_dynamic_id = 1,
};
/* All of the device info needed for the Generic Serial Converter */ /* All of the device info needed for the Generic Serial Converter */
struct usb_serial_driver usb_serial_generic_device = { struct usb_serial_driver usb_serial_generic_device = {
.driver = { .driver = {
...@@ -41,6 +60,7 @@ struct usb_serial_driver usb_serial_generic_device = { ...@@ -41,6 +60,7 @@ struct usb_serial_driver usb_serial_generic_device = {
.name = "generic", .name = "generic",
}, },
.id_table = generic_device_ids, .id_table = generic_device_ids,
.usb_driver = &generic_driver,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
.num_bulk_out = NUM_DONT_CARE, .num_bulk_out = NUM_DONT_CARE,
...@@ -48,13 +68,6 @@ struct usb_serial_driver usb_serial_generic_device = { ...@@ -48,13 +68,6 @@ struct usb_serial_driver usb_serial_generic_device = {
.shutdown = usb_serial_generic_shutdown, .shutdown = usb_serial_generic_shutdown,
}; };
/* we want to look at all devices, as the vendor/product id can change
* depending on the command line argument */
static struct usb_device_id generic_serial_ids[] = {
{.driver_info = 42},
{}
};
static int generic_probe(struct usb_interface *interface, static int generic_probe(struct usb_interface *interface,
const struct usb_device_id *id) const struct usb_device_id *id)
{ {
...@@ -65,14 +78,6 @@ static int generic_probe(struct usb_interface *interface, ...@@ -65,14 +78,6 @@ static int generic_probe(struct usb_interface *interface,
return usb_serial_probe(interface, id); return usb_serial_probe(interface, id);
return -ENODEV; return -ENODEV;
} }
static struct usb_driver generic_driver = {
.name = "usbserial_generic",
.probe = generic_probe,
.disconnect = usb_serial_disconnect,
.id_table = generic_serial_ids,
.no_dynamic_id = 1,
};
#endif #endif
int usb_serial_generic_register (int _debug) int usb_serial_generic_register (int _debug)
......
...@@ -49,6 +49,7 @@ static struct usb_serial_driver hp49gp_device = { ...@@ -49,6 +49,7 @@ static struct usb_serial_driver hp49gp_device = {
.name = "hp4X", .name = "hp4X",
}, },
.id_table = id_table, .id_table = id_table,
.usb_driver = &hp49gp_driver,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
.num_bulk_out = NUM_DONT_CARE, .num_bulk_out = NUM_DONT_CARE,
......
...@@ -242,14 +242,6 @@ static void edge_shutdown (struct usb_serial *serial); ...@@ -242,14 +242,6 @@ static void edge_shutdown (struct usb_serial *serial);
#include "io_tables.h" /* all of the devices that this driver supports */ #include "io_tables.h" /* all of the devices that this driver supports */
static struct usb_driver io_driver = {
.name = "io_edgeport",
.probe = usb_serial_probe,
.disconnect = usb_serial_disconnect,
.id_table = id_table_combined,
.no_dynamic_id = 1,
};
/* function prototypes for all of our local functions */ /* function prototypes for all of our local functions */
static void process_rcvd_data (struct edgeport_serial *edge_serial, unsigned char *buffer, __u16 bufferLength); static void process_rcvd_data (struct edgeport_serial *edge_serial, unsigned char *buffer, __u16 bufferLength);
static void process_rcvd_status (struct edgeport_serial *edge_serial, __u8 byte2, __u8 byte3); static void process_rcvd_status (struct edgeport_serial *edge_serial, __u8 byte2, __u8 byte3);
......
...@@ -95,12 +95,21 @@ static struct usb_device_id id_table_combined [] = { ...@@ -95,12 +95,21 @@ static struct usb_device_id id_table_combined [] = {
MODULE_DEVICE_TABLE (usb, id_table_combined); MODULE_DEVICE_TABLE (usb, id_table_combined);
static struct usb_driver io_driver = {
.name = "io_edgeport",
.probe = usb_serial_probe,
.disconnect = usb_serial_disconnect,
.id_table = id_table_combined,
.no_dynamic_id = 1,
};
static struct usb_serial_driver edgeport_2port_device = { static struct usb_serial_driver edgeport_2port_device = {
.driver = { .driver = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.name = "edgeport_2", .name = "edgeport_2",
}, },
.description = "Edgeport 2 port adapter", .description = "Edgeport 2 port adapter",
.usb_driver = &io_driver,
.id_table = edgeport_2port_id_table, .id_table = edgeport_2port_id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
...@@ -131,6 +140,7 @@ static struct usb_serial_driver edgeport_4port_device = { ...@@ -131,6 +140,7 @@ static struct usb_serial_driver edgeport_4port_device = {
.name = "edgeport_4", .name = "edgeport_4",
}, },
.description = "Edgeport 4 port adapter", .description = "Edgeport 4 port adapter",
.usb_driver = &io_driver,
.id_table = edgeport_4port_id_table, .id_table = edgeport_4port_id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
...@@ -161,6 +171,7 @@ static struct usb_serial_driver edgeport_8port_device = { ...@@ -161,6 +171,7 @@ static struct usb_serial_driver edgeport_8port_device = {
.name = "edgeport_8", .name = "edgeport_8",
}, },
.description = "Edgeport 8 port adapter", .description = "Edgeport 8 port adapter",
.usb_driver = &io_driver,
.id_table = edgeport_8port_id_table, .id_table = edgeport_8port_id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -2979,6 +2979,7 @@ static struct usb_serial_driver edgeport_1port_device = { ...@@ -2979,6 +2979,7 @@ static struct usb_serial_driver edgeport_1port_device = {
.name = "edgeport_ti_1", .name = "edgeport_ti_1",
}, },
.description = "Edgeport TI 1 port adapter", .description = "Edgeport TI 1 port adapter",
.usb_driver = &io_driver,
.id_table = edgeport_1port_id_table, .id_table = edgeport_1port_id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
...@@ -3009,6 +3010,7 @@ static struct usb_serial_driver edgeport_2port_device = { ...@@ -3009,6 +3010,7 @@ static struct usb_serial_driver edgeport_2port_device = {
.name = "edgeport_ti_2", .name = "edgeport_ti_2",
}, },
.description = "Edgeport TI 2 port adapter", .description = "Edgeport TI 2 port adapter",
.usb_driver = &io_driver,
.id_table = edgeport_2port_id_table, .id_table = edgeport_2port_id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 2, .num_bulk_in = 2,
......
...@@ -563,6 +563,7 @@ static struct usb_serial_driver ipaq_device = { ...@@ -563,6 +563,7 @@ static struct usb_serial_driver ipaq_device = {
.name = "ipaq", .name = "ipaq",
}, },
.description = "PocketPC PDA", .description = "PocketPC PDA",
.usb_driver = &ipaq_driver,
.id_table = ipaq_id_table, .id_table = ipaq_id_table,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -442,6 +442,7 @@ static struct usb_serial_driver ipw_device = { ...@@ -442,6 +442,7 @@ static struct usb_serial_driver ipw_device = {
.name = "ipw", .name = "ipw",
}, },
.description = "IPWireless converter", .description = "IPWireless converter",
.usb_driver = &usb_ipw_driver,
.id_table = usb_ipw_ids, .id_table = usb_ipw_ids,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -138,6 +138,7 @@ static struct usb_serial_driver ir_device = { ...@@ -138,6 +138,7 @@ static struct usb_serial_driver ir_device = {
.name = "ir-usb", .name = "ir-usb",
}, },
.description = "IR Dongle", .description = "IR Dongle",
.usb_driver = &ir_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -576,6 +576,7 @@ static struct usb_serial_driver keyspan_pre_device = { ...@@ -576,6 +576,7 @@ static struct usb_serial_driver keyspan_pre_device = {
.name = "keyspan_no_firm", .name = "keyspan_no_firm",
}, },
.description = "Keyspan - (without firmware)", .description = "Keyspan - (without firmware)",
.usb_driver = &keyspan_driver,
.id_table = keyspan_pre_ids, .id_table = keyspan_pre_ids,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
...@@ -590,6 +591,7 @@ static struct usb_serial_driver keyspan_1port_device = { ...@@ -590,6 +591,7 @@ static struct usb_serial_driver keyspan_1port_device = {
.name = "keyspan_1", .name = "keyspan_1",
}, },
.description = "Keyspan 1 port adapter", .description = "Keyspan 1 port adapter",
.usb_driver = &keyspan_driver,
.id_table = keyspan_1port_ids, .id_table = keyspan_1port_ids,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
...@@ -617,6 +619,7 @@ static struct usb_serial_driver keyspan_2port_device = { ...@@ -617,6 +619,7 @@ static struct usb_serial_driver keyspan_2port_device = {
.name = "keyspan_2", .name = "keyspan_2",
}, },
.description = "Keyspan 2 port adapter", .description = "Keyspan 2 port adapter",
.usb_driver = &keyspan_driver,
.id_table = keyspan_2port_ids, .id_table = keyspan_2port_ids,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
...@@ -644,6 +647,7 @@ static struct usb_serial_driver keyspan_4port_device = { ...@@ -644,6 +647,7 @@ static struct usb_serial_driver keyspan_4port_device = {
.name = "keyspan_4", .name = "keyspan_4",
}, },
.description = "Keyspan 4 port adapter", .description = "Keyspan 4 port adapter",
.usb_driver = &keyspan_driver,
.id_table = keyspan_4port_ids, .id_table = keyspan_4port_ids,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 5, .num_bulk_in = 5,
......
...@@ -793,6 +793,7 @@ static struct usb_serial_driver keyspan_pda_fake_device = { ...@@ -793,6 +793,7 @@ static struct usb_serial_driver keyspan_pda_fake_device = {
.name = "keyspan_pda_pre", .name = "keyspan_pda_pre",
}, },
.description = "Keyspan PDA - (prerenumeration)", .description = "Keyspan PDA - (prerenumeration)",
.usb_driver = &keyspan_pda_driver,
.id_table = id_table_fake, .id_table = id_table_fake,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
...@@ -809,6 +810,7 @@ static struct usb_serial_driver xircom_pgs_fake_device = { ...@@ -809,6 +810,7 @@ static struct usb_serial_driver xircom_pgs_fake_device = {
.name = "xircom_no_firm", .name = "xircom_no_firm",
}, },
.description = "Xircom / Entregra PGS - (prerenumeration)", .description = "Xircom / Entregra PGS - (prerenumeration)",
.usb_driver = &keyspan_pda_driver,
.id_table = id_table_fake_xircom, .id_table = id_table_fake_xircom,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
...@@ -824,6 +826,7 @@ static struct usb_serial_driver keyspan_pda_device = { ...@@ -824,6 +826,7 @@ static struct usb_serial_driver keyspan_pda_device = {
.name = "keyspan_pda", .name = "keyspan_pda",
}, },
.description = "Keyspan PDA", .description = "Keyspan PDA",
.usb_driver = &keyspan_pda_driver,
.id_table = id_table_std, .id_table = id_table_std,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 0, .num_bulk_in = 0,
......
...@@ -124,6 +124,7 @@ static struct usb_serial_driver kl5kusb105d_device = { ...@@ -124,6 +124,7 @@ static struct usb_serial_driver kl5kusb105d_device = {
.name = "kl5kusb105d", .name = "kl5kusb105d",
}, },
.description = "KL5KUSB105D / PalmConnect", .description = "KL5KUSB105D / PalmConnect",
.usb_driver = &kl5kusb105d_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -110,6 +110,7 @@ static struct usb_serial_driver kobil_device = { ...@@ -110,6 +110,7 @@ static struct usb_serial_driver kobil_device = {
.name = "kobil", .name = "kobil",
}, },
.description = "KOBIL USB smart card terminal", .description = "KOBIL USB smart card terminal",
.usb_driver = &kobil_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 0, .num_bulk_in = 0,
......
...@@ -137,6 +137,7 @@ static struct usb_serial_driver mct_u232_device = { ...@@ -137,6 +137,7 @@ static struct usb_serial_driver mct_u232_device = {
.name = "mct_u232", .name = "mct_u232",
}, },
.description = "MCT U232", .description = "MCT U232",
.usb_driver = &mct_u232_driver,
.id_table = id_table_combined, .id_table = id_table_combined,
.num_interrupt_in = 2, .num_interrupt_in = 2,
.num_bulk_in = 0, .num_bulk_in = 0,
......
...@@ -1605,12 +1605,21 @@ static void mos7720_shutdown(struct usb_serial *serial) ...@@ -1605,12 +1605,21 @@ static void mos7720_shutdown(struct usb_serial *serial)
usb_set_serial_data(serial, NULL); usb_set_serial_data(serial, NULL);
} }
static struct usb_driver usb_driver = {
.name = "moschip7720",
.probe = usb_serial_probe,
.disconnect = usb_serial_disconnect,
.id_table = moschip_port_id_table,
.no_dynamic_id = 1,
};
static struct usb_serial_driver moschip7720_2port_driver = { static struct usb_serial_driver moschip7720_2port_driver = {
.driver = { .driver = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.name = "moschip7720", .name = "moschip7720",
}, },
.description = "Moschip 2 port adapter", .description = "Moschip 2 port adapter",
.usb_driver = &usb_driver,
.id_table = moschip_port_id_table, .id_table = moschip_port_id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 2, .num_bulk_in = 2,
...@@ -1631,13 +1640,6 @@ static struct usb_serial_driver moschip7720_2port_driver = { ...@@ -1631,13 +1640,6 @@ static struct usb_serial_driver moschip7720_2port_driver = {
.read_bulk_callback = mos7720_bulk_in_callback, .read_bulk_callback = mos7720_bulk_in_callback,
}; };
static struct usb_driver usb_driver = {
.name = "moschip7720",
.probe = usb_serial_probe,
.disconnect = usb_serial_disconnect,
.id_table = moschip_port_id_table,
};
static int __init moschip7720_init(void) static int __init moschip7720_init(void)
{ {
int retval; int retval;
......
...@@ -2834,12 +2834,21 @@ static void mos7840_shutdown(struct usb_serial *serial) ...@@ -2834,12 +2834,21 @@ static void mos7840_shutdown(struct usb_serial *serial)
} }
static struct usb_driver io_driver = {
.name = "mos7840",
.probe = usb_serial_probe,
.disconnect = usb_serial_disconnect,
.id_table = moschip_id_table_combined,
.no_dynamic_id = 1,
};
static struct usb_serial_driver moschip7840_4port_device = { static struct usb_serial_driver moschip7840_4port_device = {
.driver = { .driver = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.name = "mos7840", .name = "mos7840",
}, },
.description = DRIVER_DESC, .description = DRIVER_DESC,
.usb_driver = &io_driver,
.id_table = moschip_port_id_table, .id_table = moschip_port_id_table,
.num_interrupt_in = 1, //NUM_DONT_CARE,//1, .num_interrupt_in = 1, //NUM_DONT_CARE,//1,
#ifdef check #ifdef check
...@@ -2869,13 +2878,6 @@ static struct usb_serial_driver moschip7840_4port_device = { ...@@ -2869,13 +2878,6 @@ static struct usb_serial_driver moschip7840_4port_device = {
.read_int_callback = mos7840_interrupt_callback, .read_int_callback = mos7840_interrupt_callback,
}; };
static struct usb_driver io_driver = {
.name = "mos7840",
.probe = usb_serial_probe,
.disconnect = usb_serial_disconnect,
.id_table = moschip_id_table_combined,
};
/**************************************************************************** /****************************************************************************
* moschip7840_init * moschip7840_init
* This is called by the module subsystem, or on startup to initialize us * This is called by the module subsystem, or on startup to initialize us
......
...@@ -119,6 +119,7 @@ static struct usb_serial_driver navman_device = { ...@@ -119,6 +119,7 @@ static struct usb_serial_driver navman_device = {
.name = "navman", .name = "navman",
}, },
.id_table = id_table, .id_table = id_table,
.usb_driver = &navman_driver,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
.num_bulk_out = NUM_DONT_CARE, .num_bulk_out = NUM_DONT_CARE,
......
...@@ -93,6 +93,7 @@ static struct usb_serial_driver zyxel_omninet_device = { ...@@ -93,6 +93,7 @@ static struct usb_serial_driver zyxel_omninet_device = {
.name = "omninet", .name = "omninet",
}, },
.description = "ZyXEL - omni.net lcd plus usb", .description = "ZyXEL - omni.net lcd plus usb",
.usb_driver = &omninet_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -135,6 +135,7 @@ static struct usb_serial_driver option_1port_device = { ...@@ -135,6 +135,7 @@ static struct usb_serial_driver option_1port_device = {
.name = "option1", .name = "option1",
}, },
.description = "GSM modem (1-port)", .description = "GSM modem (1-port)",
.usb_driver = &option_driver,
.id_table = option_ids1, .id_table = option_ids1,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
......
...@@ -1118,6 +1118,7 @@ static struct usb_serial_driver pl2303_device = { ...@@ -1118,6 +1118,7 @@ static struct usb_serial_driver pl2303_device = {
.name = "pl2303", .name = "pl2303",
}, },
.id_table = id_table, .id_table = id_table,
.usb_driver = &pl2303_driver,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 1, .num_bulk_in = 1,
.num_bulk_out = 1, .num_bulk_out = 1,
......
...@@ -402,6 +402,7 @@ static struct usb_serial_driver safe_device = { ...@@ -402,6 +402,7 @@ static struct usb_serial_driver safe_device = {
.name = "safe_serial", .name = "safe_serial",
}, },
.id_table = id_table, .id_table = id_table,
.usb_driver = &safe_driver,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
.num_bulk_out = NUM_DONT_CARE, .num_bulk_out = NUM_DONT_CARE,
......
...@@ -614,6 +614,7 @@ static struct usb_serial_driver sierra_1port_device = { ...@@ -614,6 +614,7 @@ static struct usb_serial_driver sierra_1port_device = {
}, },
.description = "Sierra USB modem (1 port)", .description = "Sierra USB modem (1 port)",
.id_table = id_table_1port, .id_table = id_table_1port,
.usb_driver = &sierra_driver,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 1, .num_bulk_in = 1,
.num_bulk_out = 1, .num_bulk_out = 1,
...@@ -642,6 +643,7 @@ static struct usb_serial_driver sierra_3port_device = { ...@@ -642,6 +643,7 @@ static struct usb_serial_driver sierra_3port_device = {
}, },
.description = "Sierra USB modem (3 port)", .description = "Sierra USB modem (3 port)",
.id_table = id_table_3port, .id_table = id_table_3port,
.usb_driver = &sierra_driver,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 3, .num_bulk_in = 3,
.num_bulk_out = 3, .num_bulk_out = 3,
......
...@@ -262,6 +262,7 @@ static struct usb_serial_driver ti_1port_device = { ...@@ -262,6 +262,7 @@ static struct usb_serial_driver ti_1port_device = {
.name = "ti_usb_3410_5052_1", .name = "ti_usb_3410_5052_1",
}, },
.description = "TI USB 3410 1 port adapter", .description = "TI USB 3410 1 port adapter",
.usb_driver = &ti_usb_driver,
.id_table = ti_id_table_3410, .id_table = ti_id_table_3410,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 1, .num_bulk_in = 1,
...@@ -292,6 +293,7 @@ static struct usb_serial_driver ti_2port_device = { ...@@ -292,6 +293,7 @@ static struct usb_serial_driver ti_2port_device = {
.name = "ti_usb_3410_5052_2", .name = "ti_usb_3410_5052_2",
}, },
.description = "TI USB 5052 2 port adapter", .description = "TI USB 5052 2 port adapter",
.usb_driver = &ti_usb_driver,
.id_table = ti_id_table_5052, .id_table = ti_id_table_5052,
.num_interrupt_in = 1, .num_interrupt_in = 1,
.num_bulk_in = 2, .num_bulk_in = 2,
......
...@@ -189,6 +189,7 @@ static struct usb_serial_driver handspring_device = { ...@@ -189,6 +189,7 @@ static struct usb_serial_driver handspring_device = {
.name = "visor", .name = "visor",
}, },
.description = "Handspring Visor / Palm OS", .description = "Handspring Visor / Palm OS",
.usb_driver = &visor_driver,
.id_table = id_table, .id_table = id_table,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 2, .num_bulk_in = 2,
...@@ -219,6 +220,7 @@ static struct usb_serial_driver clie_5_device = { ...@@ -219,6 +220,7 @@ static struct usb_serial_driver clie_5_device = {
.name = "clie_5", .name = "clie_5",
}, },
.description = "Sony Clie 5.0", .description = "Sony Clie 5.0",
.usb_driver = &visor_driver,
.id_table = clie_id_5_table, .id_table = clie_id_5_table,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = 2, .num_bulk_in = 2,
...@@ -249,6 +251,7 @@ static struct usb_serial_driver clie_3_5_device = { ...@@ -249,6 +251,7 @@ static struct usb_serial_driver clie_3_5_device = {
.name = "clie_3.5", .name = "clie_3.5",
}, },
.description = "Sony Clie 3.5", .description = "Sony Clie 3.5",
.usb_driver = &visor_driver,
.id_table = clie_id_3_5_table, .id_table = clie_id_3_5_table,
.num_interrupt_in = 0, .num_interrupt_in = 0,
.num_bulk_in = 1, .num_bulk_in = 1,
......
...@@ -161,6 +161,7 @@ static struct usb_serial_driver whiteheat_fake_device = { ...@@ -161,6 +161,7 @@ static struct usb_serial_driver whiteheat_fake_device = {
.name = "whiteheatnofirm", .name = "whiteheatnofirm",
}, },
.description = "Connect Tech - WhiteHEAT - (prerenumeration)", .description = "Connect Tech - WhiteHEAT - (prerenumeration)",
.usb_driver = &whiteheat_driver,
.id_table = id_table_prerenumeration, .id_table = id_table_prerenumeration,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
...@@ -176,6 +177,7 @@ static struct usb_serial_driver whiteheat_device = { ...@@ -176,6 +177,7 @@ static struct usb_serial_driver whiteheat_device = {
.name = "whiteheat", .name = "whiteheat",
}, },
.description = "Connect Tech - WhiteHEAT", .description = "Connect Tech - WhiteHEAT",
.usb_driver = &whiteheat_driver,
.id_table = id_table_std, .id_table = id_table_std,
.num_interrupt_in = NUM_DONT_CARE, .num_interrupt_in = NUM_DONT_CARE,
.num_bulk_in = NUM_DONT_CARE, .num_bulk_in = NUM_DONT_CARE,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment