aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial/mos7840.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/serial/mos7840.c')
-rw-r--r--drivers/usb/serial/mos7840.c26
1 files changed, 11 insertions, 15 deletions
diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c
index 5432c6340086..b2264a87617b 100644
--- a/drivers/usb/serial/mos7840.c
+++ b/drivers/usb/serial/mos7840.c
@@ -1931,7 +1931,7 @@ static int mos7840_send_cmd_write_baud_rate(struct moschip_port *mos7840_port,
1931 *****************************************************************************/ 1931 *****************************************************************************/
1932 1932
1933static void mos7840_change_port_settings(struct moschip_port *mos7840_port, 1933static void mos7840_change_port_settings(struct moschip_port *mos7840_port,
1934 struct termios *old_termios) 1934 struct ktermios *old_termios)
1935{ 1935{
1936 struct tty_struct *tty; 1936 struct tty_struct *tty;
1937 int baud; 1937 int baud;
@@ -2118,7 +2118,7 @@ static void mos7840_change_port_settings(struct moschip_port *mos7840_port,
2118 *****************************************************************************/ 2118 *****************************************************************************/
2119 2119
2120static void mos7840_set_termios(struct usb_serial_port *port, 2120static void mos7840_set_termios(struct usb_serial_port *port,
2121 struct termios *old_termios) 2121 struct ktermios *old_termios)
2122{ 2122{
2123 int status; 2123 int status;
2124 unsigned int cflag; 2124 unsigned int cflag;
@@ -2460,12 +2460,6 @@ static int mos7840_ioctl(struct usb_serial_port *port, struct file *file,
2460 tty_ldisc_deref(ld); 2460 tty_ldisc_deref(ld);
2461 return 0; 2461 return 0;
2462 2462
2463 case TCGETS:
2464 if (kernel_termios_to_user_termios
2465 ((struct termios __user *)argp, tty->termios))
2466 return -EFAULT;
2467 return 0;
2468
2469 case TIOCSERGETLSR: 2463 case TIOCSERGETLSR:
2470 dbg("%s (%d) TIOCSERGETLSR", __FUNCTION__, port->number); 2464 dbg("%s (%d) TIOCSERGETLSR", __FUNCTION__, port->number);
2471 return mos7840_get_lsr_info(mos7840_port, argp); 2465 return mos7840_get_lsr_info(mos7840_port, argp);
@@ -2840,12 +2834,21 @@ static void mos7840_shutdown(struct usb_serial *serial)
2840 2834
2841} 2835}
2842 2836
2837static struct usb_driver io_driver = {
2838 .name = "mos7840",
2839 .probe = usb_serial_probe,
2840 .disconnect = usb_serial_disconnect,
2841 .id_table = moschip_id_table_combined,
2842 .no_dynamic_id = 1,
2843};
2844
2843static struct usb_serial_driver moschip7840_4port_device = { 2845static struct usb_serial_driver moschip7840_4port_device = {
2844 .driver = { 2846 .driver = {
2845 .owner = THIS_MODULE, 2847 .owner = THIS_MODULE,
2846 .name = "mos7840", 2848 .name = "mos7840",
2847 }, 2849 },
2848 .description = DRIVER_DESC, 2850 .description = DRIVER_DESC,
2851 .usb_driver = &io_driver,
2849 .id_table = moschip_port_id_table, 2852 .id_table = moschip_port_id_table,
2850 .num_interrupt_in = 1, //NUM_DONT_CARE,//1, 2853 .num_interrupt_in = 1, //NUM_DONT_CARE,//1,
2851#ifdef check 2854#ifdef check
@@ -2875,13 +2878,6 @@ static struct usb_serial_driver moschip7840_4port_device = {
2875 .read_int_callback = mos7840_interrupt_callback, 2878 .read_int_callback = mos7840_interrupt_callback,
2876}; 2879};
2877 2880
2878static struct usb_driver io_driver = {
2879 .name = "mos7840",
2880 .probe = usb_serial_probe,
2881 .disconnect = usb_serial_disconnect,
2882 .id_table = moschip_id_table_combined,
2883};
2884
2885/**************************************************************************** 2881/****************************************************************************
2886 * moschip7840_init 2882 * moschip7840_init
2887 * This is called by the module subsystem, or on startup to initialize us 2883 * This is called by the module subsystem, or on startup to initialize us