Commit fb1ca99e authored by Sebastian Andrzej Siewior's avatar Sebastian Andrzej Siewior Committed by Greg Kroah-Hartman

serial: 8250: Revert "tty: serial: 8250_core: read only RX if there is something in the FIFO"

commit ca8bb4ae upstream.

This reverts commit 0aa525d1.

The conditional RX-FIFO read seems to cause spurious interrupts and we
see just:
|serial8250: too much work for irq29

The previous behaviour was "default" for decades and Marvell's 88f6282 SoC
might not be the only that relies on it. Therefore the Omap fix is
reverted for now.

Fixes: 0aa525d1 ("tty: serial: 8250_core: read only RX if there is
something in the FIFO")
Reported-By: default avatarNicolas Schichan <nschichan@freebox.fr>
Debuged-By: default avatarPeter Hurley <peter@hurleysoftware.com>
Signed-off-by: default avatarSebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c6656cf2
...@@ -2107,7 +2107,7 @@ int serial8250_do_startup(struct uart_port *port) ...@@ -2107,7 +2107,7 @@ int serial8250_do_startup(struct uart_port *port)
/* /*
* Clear the interrupt registers. * Clear the interrupt registers.
*/ */
if (serial_port_in(port, UART_LSR) & UART_LSR_DR) serial_port_in(port, UART_LSR);
serial_port_in(port, UART_RX); serial_port_in(port, UART_RX);
serial_port_in(port, UART_IIR); serial_port_in(port, UART_IIR);
serial_port_in(port, UART_MSR); serial_port_in(port, UART_MSR);
...@@ -2269,7 +2269,7 @@ int serial8250_do_startup(struct uart_port *port) ...@@ -2269,7 +2269,7 @@ int serial8250_do_startup(struct uart_port *port)
* saved flags to avoid getting false values from polling * saved flags to avoid getting false values from polling
* routines or the previous session. * routines or the previous session.
*/ */
if (serial_port_in(port, UART_LSR) & UART_LSR_DR) serial_port_in(port, UART_LSR);
serial_port_in(port, UART_RX); serial_port_in(port, UART_RX);
serial_port_in(port, UART_IIR); serial_port_in(port, UART_IIR);
serial_port_in(port, UART_MSR); serial_port_in(port, UART_MSR);
...@@ -2363,7 +2363,6 @@ void serial8250_do_shutdown(struct uart_port *port) ...@@ -2363,7 +2363,6 @@ void serial8250_do_shutdown(struct uart_port *port)
* Read data port to reset things, and then unlink from * Read data port to reset things, and then unlink from
* the IRQ chain. * the IRQ chain.
*/ */
if (serial_port_in(port, UART_LSR) & UART_LSR_DR)
serial_port_in(port, UART_RX); serial_port_in(port, UART_RX);
serial8250_rpm_put(up); serial8250_rpm_put(up);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment