[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z3ewRTKw-jh_bJ73@pathway.suse.cz>
Date: Fri, 3 Jan 2025 10:39:17 +0100
From: Petr Mladek <pmladek@...e.com>
To: John Ogness <john.ogness@...utronix.de>
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Jiri Slaby <jirislaby@...nel.org>,
Sergey Senozhatsky <senozhatsky@...omium.org>,
Steven Rostedt <rostedt@...dmis.org>,
Thomas Gleixner <tglx@...utronix.de>,
Esben Haabendal <esben@...nix.com>, linux-serial@...r.kernel.org,
linux-kernel@...r.kernel.org,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Arnd Bergmann <arnd@...db.de>,
Rengarajan S <rengarajan.s@...rochip.com>,
Niklas Schnelle <schnelle@...ux.ibm.com>,
Serge Semin <fancer.lancer@...il.com>,
Wander Lairson Costa <wander@...hat.com>
Subject: Re: [PATCH tty-next v4 1/6] serial: 8250: Adjust the timeout for
FIFO mode
On Fri 2024-12-27 23:51:17, John Ogness wrote:
> After a console has written a record into UART_TX, it uses
> wait_for_xmitr() to wait until the data has been sent out before
> returning. However, wait_for_xmitr() will timeout after 10ms,
> regardless if the data has been transmitted or not.
>
> For single bytes, this timeout is sufficient even at very slow
> baud rates, such as 1200bps. However, when FIFO mode is used,
> there may be 64 bytes pushed into the FIFO at once. At a baud
> rate of 115200bps, the 10ms timeout is still sufficient. But
> when using lower baud rates (such as 57600bps), the timeout
> is _not_ sufficient. This causes longer lines to be cut off,
> resulting in lost and horribly misformatted output on the
> console.
>
> When using FIFO mode, take the number of bytes into account to
> determine an appropriate maximum timeout. Increasing the timeout
> does not affect performance since ideally the timeout never
> occurs.
>
> Fixes: 8f3631f0f6eb ("serial/8250: Use fifo in 8250 console driver")
> Signed-off-by: John Ogness <john.ogness@...utronix.de>
> Reviewed-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> Reviewed-by: Wander Lairson Costa <wander@...hat.com>
Looks good to me:
Reviewed-by: Petr Mladek <pmladek@...e.com>
Best Regards,
Petr
Powered by blists - more mailing lists