summaryrefslogtreecommitdiffstats
path: root/drivers/tty/serial/ucc_uart.c
diff options
context:
space:
mode:
authorChuck Meade <chuck@ThePTRGroup.com>2010-06-18 09:22:26 -0400
committerKumar Gala <galak@kernel.crashing.org>2011-11-24 02:23:45 -0600
commit8e18862d52b8ecd62354dad117aff22391b2c4e5 (patch)
treefc2ac3d6fdf0739b882976a37a8f949b10037c5b /drivers/tty/serial/ucc_uart.c
parent895d603f945baf7d1680b7657561212890e3a803 (diff)
downloadop-kernel-dev-8e18862d52b8ecd62354dad117aff22391b2c4e5.zip
op-kernel-dev-8e18862d52b8ecd62354dad117aff22391b2c4e5.tar.gz
drivers/serial/ucc_uart.c: Add missing call to init UCC UART port timeout
The UCC UART driver is missing a call to uart_update_timeout(). Without this call, attempting to close the port after outputting large amounts of data (i.e. using tty and uart buffering) results in long timeouts before the port will actually be shut down. For example, cat a large file to a UCC UART port. With the current driver, the port will stay open for 30 seconds after the last byte of data is output. But with this patch, the port is closed as expected, just after the data has been output (tx fifos empty). Signed-off-by: Chuck Meade <chuck@ThePTRGroup.com> Acked-by: Timur Tabi <timur@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'drivers/tty/serial/ucc_uart.c')
-rw-r--r--drivers/tty/serial/ucc_uart.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/tty/serial/ucc_uart.c b/drivers/tty/serial/ucc_uart.c
index cea8918..2ebe606 100644
--- a/drivers/tty/serial/ucc_uart.c
+++ b/drivers/tty/serial/ucc_uart.c
@@ -963,6 +963,9 @@ static void qe_uart_set_termios(struct uart_port *port,
/* Do we really need a spinlock here? */
spin_lock_irqsave(&port->lock, flags);
+ /* Update the per-port timeout. */
+ uart_update_timeout(port, termios->c_cflag, baud);
+
out_be16(&uccp->upsmr, upsmr);
if (soft_uart) {
out_be16(&uccup->supsmr, supsmr);
OpenPOWER on IntegriCloud