Re: [PATCH 4/8] serial: 8250: Handle case port doesn't have TEMT interrupt using em485.

From: Andy Shevchenko
Date: Mon Jun 04 2018 - 06:17:55 EST


On Fri, 2018-06-01 at 14:40 +0200, Giulio Benetti wrote:
> Some 8250 ports only have TEMT interrupt, so current implementation
> can't work for ports without it. The only chance to make it work is to
> loop-read on LSR register.
>
> With NO TEMT interrupt check if both TEMT and THRE are set looping on
> LSR register.

> --- a/drivers/tty/serial/8250/8250_dw.c
> +++ b/drivers/tty/serial/8250/8250_dw.c

> - int ret = serial8250_em485_init(up);
> + int ret = serial8250_em485_init(up, false);

Is true for all possible DW configured types? Or it's your particular
case?

--
Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>
Intel Finland Oy