aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial
diff options
context:
space:
mode:
authorAlan Cox <alan@redhat.com>2008-07-22 06:14:22 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-07-22 16:03:25 -0400
commitb31f658b0bb42b315c22ae2ef814e5fba36ac737 (patch)
treeb7a811ff4d74868b2efdb2cd870d759ebe9111a5 /drivers/usb/serial
parentdee0a7ccaa0bcdeebb590879d68739cce4ff1b07 (diff)
kobil_sct: Fix ioctls
Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/usb/serial')
-rw-r--r--drivers/usb/serial/kobil_sct.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/usb/serial/kobil_sct.c b/drivers/usb/serial/kobil_sct.c
index f0f8353ec1ac..deba28ec77e8 100644
--- a/drivers/usb/serial/kobil_sct.c
+++ b/drivers/usb/serial/kobil_sct.c
@@ -640,9 +640,11 @@ static void kobil_set_termios(struct tty_struct *tty,
640 640
641 priv = usb_get_serial_port_data(port); 641 priv = usb_get_serial_port_data(port);
642 if (priv->device_type == KOBIL_USBTWIN_PRODUCT_ID || 642 if (priv->device_type == KOBIL_USBTWIN_PRODUCT_ID ||
643 priv->device_type == KOBIL_KAAN_SIM_PRODUCT_ID) 643 priv->device_type == KOBIL_KAAN_SIM_PRODUCT_ID) {
644 /* This device doesn't support ioctl calls */ 644 /* This device doesn't support ioctl calls */
645 *tty->termios = *old;
645 return; 646 return;
647 }
646 648
647 speed = tty_get_baud_rate(tty); 649 speed = tty_get_baud_rate(tty);
648 switch (speed) { 650 switch (speed) {
@@ -704,7 +706,7 @@ static int kobil_ioctl(struct tty_struct *tty, struct file *file,
704 if (priv->device_type == KOBIL_USBTWIN_PRODUCT_ID || 706 if (priv->device_type == KOBIL_USBTWIN_PRODUCT_ID ||
705 priv->device_type == KOBIL_KAAN_SIM_PRODUCT_ID) 707 priv->device_type == KOBIL_KAAN_SIM_PRODUCT_ID)
706 /* This device doesn't support ioctl calls */ 708 /* This device doesn't support ioctl calls */
707 return 0; 709 return -ENOIOCTLCMD;
708 710
709 switch (cmd) { 711 switch (cmd) {
710 case TCFLSH: 712 case TCFLSH: