Merge branch 'release-2.6.27' of git://git.kernel.org/pub/scm/linux/kernel/git/ak...
[pandora-kernel.git] / drivers / usb / serial / io_tables.h
index fad561c..7eb9d67 100644 (file)
@@ -8,7 +8,7 @@
  *     it under the terms of the GNU General Public License as published by
  *     the Free Software Foundation; either version 2 of the License, or
  *     (at your option) any later version.
- * 
+ *
  */
 
 #ifndef IO_TABLES_H
@@ -47,6 +47,18 @@ static struct usb_device_id edgeport_8port_id_table [] = {
        { }
 };
 
+static struct usb_device_id Epic_port_id_table [] = {
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0202) },
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0203) },
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0310) },
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0311) },
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0312) },
+       { USB_DEVICE(USB_VENDOR_ID_AXIOHM, AXIOHM_DEVICE_ID_EPIC_A758) },
+       { USB_DEVICE(USB_VENDOR_ID_AXIOHM, AXIOHM_DEVICE_ID_EPIC_A794) },
+       { USB_DEVICE(USB_VENDOR_ID_AXIOHM, AXIOHM_DEVICE_ID_EPIC_A225) },
+       { }
+};
+
 /* Devices that this driver supports */
 static struct usb_device_id id_table_combined [] = {
        { USB_DEVICE(USB_VENDOR_ID_ION, ION_DEVICE_ID_EDGEPORT_4) },
@@ -70,10 +82,26 @@ static struct usb_device_id id_table_combined [] = {
        { USB_DEVICE(USB_VENDOR_ID_ION, ION_DEVICE_ID_EDGEPORT_8R) },
        { USB_DEVICE(USB_VENDOR_ID_ION, ION_DEVICE_ID_EDGEPORT_8RR) },
        { USB_DEVICE(USB_VENDOR_ID_ION, ION_DEVICE_ID_EDGEPORT_412_8) },
-       { }                                                     /* Terminating entry */
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0202) },
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0203) },
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0310) },
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0311) },
+       { USB_DEVICE(USB_VENDOR_ID_NCR, NCR_DEVICE_ID_EPIC_0312) },
+       { USB_DEVICE(USB_VENDOR_ID_AXIOHM, AXIOHM_DEVICE_ID_EPIC_A758) },
+       { USB_DEVICE(USB_VENDOR_ID_AXIOHM, AXIOHM_DEVICE_ID_EPIC_A794) },
+       { USB_DEVICE(USB_VENDOR_ID_AXIOHM, AXIOHM_DEVICE_ID_EPIC_A225) },
+       { } /* Terminating entry */
 };
 
-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 = {
        .driver = {
@@ -81,10 +109,8 @@ static struct usb_serial_driver edgeport_2port_device = {
                .name           = "edgeport_2",
        },
        .description            = "Edgeport 2 port adapter",
+       .usb_driver             = &io_driver,
        .id_table               = edgeport_2port_id_table,
-       .num_interrupt_in       = 1,
-       .num_bulk_in            = 1,
-       .num_bulk_out           = 1,
        .num_ports              = 2,
        .open                   = edge_open,
        .close                  = edge_close,
@@ -111,10 +137,8 @@ static struct usb_serial_driver edgeport_4port_device = {
                .name           = "edgeport_4",
        },
        .description            = "Edgeport 4 port adapter",
+       .usb_driver             = &io_driver,
        .id_table               = edgeport_4port_id_table,
-       .num_interrupt_in       = 1,
-       .num_bulk_in            = 1,
-       .num_bulk_out           = 1,
        .num_ports              = 4,
        .open                   = edge_open,
        .close                  = edge_close,
@@ -141,10 +165,8 @@ static struct usb_serial_driver edgeport_8port_device = {
                .name           = "edgeport_8",
        },
        .description            = "Edgeport 8 port adapter",
+       .usb_driver             = &io_driver,
        .id_table               = edgeport_8port_id_table,
-       .num_interrupt_in       = 1,
-       .num_bulk_in            = 1,
-       .num_bulk_out           = 1,
        .num_ports              = 8,
        .open                   = edge_open,
        .close                  = edge_close,
@@ -165,5 +187,32 @@ static struct usb_serial_driver edgeport_8port_device = {
        .write_bulk_callback    = edge_bulk_out_data_callback,
 };
 
+static struct usb_serial_driver epic_device = {
+       .driver = {
+               .owner          = THIS_MODULE,
+               .name           = "epic",
+       },
+       .description            = "EPiC device",
+       .id_table               = Epic_port_id_table,
+       .num_ports              = 1,
+       .open                   = edge_open,
+       .close                  = edge_close,
+       .throttle               = edge_throttle,
+       .unthrottle             = edge_unthrottle,
+       .attach                 = edge_startup,
+       .shutdown               = edge_shutdown,
+       .ioctl                  = edge_ioctl,
+       .set_termios            = edge_set_termios,
+       .tiocmget               = edge_tiocmget,
+       .tiocmset               = edge_tiocmset,
+       .write                  = edge_write,
+       .write_room             = edge_write_room,
+       .chars_in_buffer        = edge_chars_in_buffer,
+       .break_ctl              = edge_break,
+       .read_int_callback      = edge_interrupt_callback,
+       .read_bulk_callback     = edge_bulk_in_callback,
+       .write_bulk_callback    = edge_bulk_out_data_callback,
+};
+
 #endif