]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/usb/serial/mos7840.c
[PATCH] trivial usb endianness annotations
[linux-2.6-omap-h63xx.git] / drivers / usb / serial / mos7840.c
index 02c89e10b2cf103752c72d993d3aa7cf2cfd98b5..b2264a87617bdfdde5587bd3cee5cc2de82edc87 100644 (file)
@@ -826,7 +826,7 @@ static int mos7840_open(struct usb_serial_port *port, struct file *filp)
 
        /* Initialising the write urb pool */
        for (j = 0; j < NUM_URBS; ++j) {
-               urb = usb_alloc_urb(0, SLAB_ATOMIC);
+               urb = usb_alloc_urb(0, GFP_ATOMIC);
                mos7840_port->write_urb_pool[j] = urb;
 
                if (urb == NULL) {
@@ -1931,7 +1931,7 @@ static int mos7840_send_cmd_write_baud_rate(struct moschip_port *mos7840_port,
  *****************************************************************************/
 
 static void mos7840_change_port_settings(struct moschip_port *mos7840_port,
-                                        struct termios *old_termios)
+                                        struct ktermios *old_termios)
 {
        struct tty_struct *tty;
        int baud;
@@ -2118,7 +2118,7 @@ static void mos7840_change_port_settings(struct moschip_port *mos7840_port,
  *****************************************************************************/
 
 static void mos7840_set_termios(struct usb_serial_port *port,
-                               struct termios *old_termios)
+                               struct ktermios *old_termios)
 {
        int status;
        unsigned int cflag;
@@ -2460,12 +2460,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);
@@ -2786,7 +2780,7 @@ static int mos7840_startup(struct usb_serial *serial)
                                    i + 1, status);
 
                }
-               mos7840_port->control_urb = usb_alloc_urb(0, SLAB_ATOMIC);
+               mos7840_port->control_urb = usb_alloc_urb(0, GFP_ATOMIC);
                mos7840_port->ctrl_buf = kmalloc(16, GFP_KERNEL);
 
        }
@@ -2840,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 = {
        .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 +2878,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