diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-10-05 18:48:28 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-11-04 06:25:57 -0500 |
commit | 0d5b16639523970db001e6af298e360782f4d89a (patch) | |
tree | 1eda52e168eb796758eeda35cd9c5e28fde9571f /drivers/tty | |
parent | 9aba8d5b011193c8e01d565c5b585df5b94f1db2 (diff) |
SERIAL: omap: allow hardware assisted rts/cts modes to be disabled
There is nothing which clears the auto RTS/CTS bits, so once hardware
flow control gets enabled, there's no possibility to disable it.
So, clear these bits when CRTSCTS is cleared.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/tty')
-rw-r--r-- | drivers/tty/serial/omap-serial.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c index 6d3d26a607b9..b6a1925dfc92 100644 --- a/drivers/tty/serial/omap-serial.c +++ b/drivers/tty/serial/omap-serial.c | |||
@@ -921,6 +921,13 @@ serial_omap_set_termios(struct uart_port *port, struct ktermios *termios, | |||
921 | serial_out(up, UART_LCR, UART_LCR_CONF_MODE_A); | 921 | serial_out(up, UART_LCR, UART_LCR_CONF_MODE_A); |
922 | serial_out(up, UART_MCR, up->mcr | UART_MCR_RTS); | 922 | serial_out(up, UART_MCR, up->mcr | UART_MCR_RTS); |
923 | serial_out(up, UART_LCR, cval); | 923 | serial_out(up, UART_LCR, cval); |
924 | } else { | ||
925 | /* Disable AUTORTS and AUTOCTS */ | ||
926 | up->efr &= ~(UART_EFR_CTS | UART_EFR_RTS); | ||
927 | |||
928 | serial_out(up, UART_LCR, UART_LCR_CONF_MODE_B); | ||
929 | serial_out(up, UART_EFR, up->efr); | ||
930 | serial_out(up, UART_LCR, cval); | ||
924 | } | 931 | } |
925 | 932 | ||
926 | serial_omap_set_mctrl(&up->port, up->port.mctrl); | 933 | serial_omap_set_mctrl(&up->port, up->port.mctrl); |