Merge git://oss.sgi.com:8090/xfs/xfs-2.6
[linux-drm-fsl-dcu.git] / drivers / usb / serial / mos7840.c
index 8cc728a49e41fce1b644e42507c2106491bc6ac6..c6cca859af452706ccc4bc756877df4e81af1fc3 100644 (file)
@@ -755,18 +755,8 @@ static void mos7840_bulk_out_data_callback(struct urb *urb)
 
        tty = mos7840_port->port->tty;
 
-       if (tty && mos7840_port->open) {
-               /* let the tty driver wakeup if it has a special *
-                * write_wakeup function                         */
-
-               if ((tty->flags & (1 << TTY_DO_WRITE_WAKEUP))
-                   && tty->ldisc.write_wakeup) {
-                       (tty->ldisc.write_wakeup) (tty);
-               }
-
-               /* tell the tty driver that something has changed */
-               wake_up_interruptible(&tty->write_wait);
-       }
+       if (tty && mos7840_port->open)
+               tty_wakeup(tty);
 
 }
 
@@ -2460,12 +2450,6 @@ static int mos7840_ioctl(struct usb_serial_port *port, struct file *file,
                tty_ldisc_deref(ld);
                return 0;
 
-       case TCGETS:
-               if (kernel_termios_to_user_termios
-                   ((struct termios __user *)argp, tty->termios))
-                       return -EFAULT;
-               return 0;
-
        case TIOCSERGETLSR:
                dbg("%s (%d) TIOCSERGETLSR", __FUNCTION__, port->number);
                return mos7840_get_lsr_info(mos7840_port, argp);
@@ -2840,12 +2824,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 = {
        .driver = {
                   .owner = THIS_MODULE,
                   .name = "mos7840",
                   },
        .description = DRIVER_DESC,
+       .usb_driver = &io_driver,
        .id_table = moschip_port_id_table,
        .num_interrupt_in = 1,  //NUM_DONT_CARE,//1,
 #ifdef check
@@ -2875,13 +2868,6 @@ static struct usb_serial_driver moschip7840_4port_device = {
        .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
  *     This is called by the module subsystem, or on startup to initialize us