serial: stm32: fix pio transmit timeout
authorGerald Baeza <gerald.baeza@st.com>
Mon, 31 Jul 2017 09:31:52 +0000 (09:31 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 28 Aug 2017 18:51:19 +0000 (20:51 +0200)
100µs was too short for low speed transmission
(9600bps)

Signed-off-by: Gerald Baeza <gerald.baeza@st.com>
Signed-off-by: Bich Hemon <bich.hemon@st.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/stm32-usart.c

index 72c0ec145527ac5d4b75d06e067c8eadb4706a9d..b16e7e7961551f2ae28f52f2d012f7fa1902bdc1 100644 (file)
@@ -203,7 +203,7 @@ static void stm32_transmit_chars_pio(struct uart_port *port)
        ret = readl_relaxed_poll_timeout_atomic(port->membase + ofs->isr,
                                                isr,
                                                (isr & USART_SR_TXE),
-                                               10, 100);
+                                               10, 100000);
 
        if (ret)
                dev_err(port->dev, "tx empty not set\n");