Hi All,
This is a more disputable item. I believe that it is better to protect
with spinlocks any fiddling in intterupt registers/variables. This patch
makes it more robust (in my view).
--- drivers/serial/8250.c.orig 2007-06-11 20:37:06.000000000 +0200
+++ drivers/serial/8250.c 2007-06-19 14:54:02.000000000 +0200
@@ -1937,7 +1937,8 @@ serial8250_set_termios(struct uart_port
if (up->bugs & UART_BUG_QUOT && (quot & 0xff) == 0)
quot ++;
- if (up->capabilities & UART_CAP_FIFO && up->port.fifosize > 1) {
+ if (up->capabilities & UART_CAP_FIFO &&
+ uart_config[up->port.type].fifosize > 1) {
if (baud < 2400)
fcr = UART_FCR_ENABLE_FIFO | UART_FCR_TRIGGER_1;
else
@@ -1952,7 +1953,8 @@ serial8250_set_termios(struct uart_port
* have sufficient FIFO entries for the latency of the remote
* UART to respond. IOW, at least 32 bytes of FIFO.
*/
- if (up->capabilities & UART_CAP_AFE && up->port.fifosize >= 32) {
+ if (up->capabilities & UART_CAP_AFE &&
+ uart_config[up->port.type].fifosize >= 32) {
up->mcr &= ~UART_MCR_AFE;
if (termios->c_cflag & CRTSCTS)
up->mcr |= UART_MCR_AFE;
regards
Kees
-
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html