[PATCH] USB: Fix baud selection in mct_u232
Linux Kernel Mailing List <[email protected]> Wed, 23 Mar 2005 16:00:39 +0000
| Newsgroups | gmane.linux.kernel.commits.2-4 |
|---|---|
| Message-ID | <[email protected]> |
ChangeSet 1.1469, 2005/03/23 13:00:39-03:00, [email protected] [PATCH] USB: Fix baud selection in mct_u232 This is an obvious fix by Hansjoerg Lipp, which fixes baud rate selection for one of two types of MCT adapters. Unfortunately, I only have the other type, and so I let it slip in. I have tested this to build and not break my type. This fix is not yet present in Linus's 2.6, but I am confident that it will make it in due time. I keep MCT synched between 2.4 and 2.6, this patch applies to both trees. mct_u232.c | 22 +++++++++++----------- 1 files changed, 11 insertions(+), 11 deletions(-) diff -Nru a/drivers/usb/serial/mct_u232.c b/drivers/usb/serial/mct_u232.c --- a/drivers/usb/serial/mct_u232.c 2005-03-24 09:05:42 -08:00 +++ b/drivers/usb/serial/mct_u232.c 2005-03-24 09:05:42 -08:00 @@ -190,16 +190,16 @@ } } else { switch (value) { - case B300: value = 300; - case B600: value = 600; - case B1200: value = 1200; - case B2400: value = 2400; - case B4800: value = 4800; - case B9600: value = 9600; - case B19200: value = 19200; - case B38400: value = 38400; - case B57600: value = 57600; - case B115200: value = 115200; + case B300: value = 300; break; + case B600: value = 600; break; + case B1200: value = 1200; break; + case B2400: value = 2400; break; + case B4800: value = 4800; break; + case B9600: value = 9600; break; + case B19200: value = 19200; break; + case B38400: value = 38400; break; + case B57600: value = 57600; break; + case B115200: value = 115200; break; default: err("MCT USB-RS232: unsupported baudrate request 0x%x," " using default of B9600", value); @@ -667,7 +667,7 @@ else new_state &= ~(TIOCM_DTR | TIOCM_RTS); if (new_state != control_state) { - mct_u232_set_modem_ctrl(serial, control_state); + mct_u232_set_modem_ctrl(serial, new_state); control_state = new_state; }