diff options
author | Alan Cox <alan@lxorguk.ukuu.org.uk> | 2008-04-28 05:14:06 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-28 11:58:29 -0400 |
commit | e991a2bd4fa0b2f475b67dfe8f33e8ecbdcbb40b (patch) | |
tree | 9fc9dab71bc47d38e31fc2e55247b928bfa516d5 /drivers/serial/8250.c | |
parent | ce9f9f73af0338a680d66288cbf0efe4b900e78b (diff) |
Fix tty speed handling on 8250
We try and write the correct speed back but the serial midlayer already
mangles the speed on us and that means if we request B0 we report back B9600
when we should not. For now we'll hack around this in the drivers and serial
code, pending a better long term solution.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/serial/8250.c')
-rw-r--r-- | drivers/serial/8250.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/serial/8250.c b/drivers/serial/8250.c index 96a585e1cee8..6d0ce64163e5 100644 --- a/drivers/serial/8250.c +++ b/drivers/serial/8250.c | |||
@@ -2228,7 +2228,9 @@ serial8250_set_termios(struct uart_port *port, struct ktermios *termios, | |||
2228 | } | 2228 | } |
2229 | serial8250_set_mctrl(&up->port, up->port.mctrl); | 2229 | serial8250_set_mctrl(&up->port, up->port.mctrl); |
2230 | spin_unlock_irqrestore(&up->port.lock, flags); | 2230 | spin_unlock_irqrestore(&up->port.lock, flags); |
2231 | tty_termios_encode_baud_rate(termios, baud, baud); | 2231 | /* Don't rewrite B0 */ |
2232 | if (tty_termios_baud_rate(termios)) | ||
2233 | tty_termios_encode_baud_rate(termios, baud, baud); | ||
2232 | } | 2234 | } |
2233 | 2235 | ||
2234 | static void | 2236 | static void |