lkml.org 
[lkml]   [2005]   [Jan]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectBug when using custom baud rates....
Hi,

When using custom baud rates, the code does:


if ((new_serial.baud_base != priv->baud_base) ||
(new_serial.baud_base < 9600))
return -EINVAL;

Which translates to english as:

If you changed the baud-base, OR the new one is
invalid, return invalid.

but it should be:

If you changed the baud-base, OR the new one is
invalid, return invalid.

Patch attached.

Roger.

--
** R.E.Wolff@BitWizard.nl ** http://www.BitWizard.nl/ ** +31-15-2600998 **
*-- BitWizard writes Linux device drivers for any device you may have! --*
Q: It doesn't work. A: Look buddy, doesn't work is an ambiguous statement.
Does it sit on the couch all day? Is it unemployed? Please be specific!
Define 'it' and what it isn't doing. --------- Adapted from lxrbot FAQ
diff -ur linux-2.4.28.clean/drivers/usb/serial/ftdi_sio.c linux-2.4.28.ftdi_fix/drivers/usb/serial/ftdi_sio.c
--- linux-2.4.28.clean/drivers/usb/serial/ftdi_sio.c Wed Jan 19 16:31:03 2005
+++ linux-2.4.28.ftdi_fix/drivers/usb/serial/ftdi_sio.c Thu Jan 20 15:47:49 2005
@@ -981,7 +981,7 @@
goto check_and_exit;
}

- if ((new_serial.baud_base != priv->baud_base) ||
+ if ((new_serial.baud_base != priv->baud_base) &&
(new_serial.baud_base < 9600))
return -EINVAL;

Only in linux-2.4.28.ftdi_fix/drivers/usb/serial: ftdi_sio.c~
\
 
 \ /
  Last update: 2005-03-22 14:09    [W:0.032 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site