diff options
author | Gabriel Somlo <gsomlo@gmail.com> | 2022-11-23 08:04:53 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-01-19 14:59:40 +0100 |
commit | 771268843caa3ecd3fa43b05a6d1d74700785ad8 (patch) | |
tree | 3708d2d0064ef9deceaa7f320ba805b9220083c5 /drivers/tty/serial | |
parent | 2ee91d42bf5ac2f2f2862d06f7344ffe89d4a032 (diff) | |
download | linux-stable-771268843caa3ecd3fa43b05a6d1d74700785ad8.tar.gz linux-stable-771268843caa3ecd3fa43b05a6d1d74700785ad8.tar.bz2 linux-stable-771268843caa3ecd3fa43b05a6d1d74700785ad8.zip |
serial: liteuart: rx loop should only ack rx events
While receiving characters, it is necessary to acknowledge each one
by writing to the EV_PENDING register's EV_RX bit. Ensure we do not
also gratuitously set the EV_TX bit in the process.
Signed-off-by: Gabriel Somlo <gsomlo@gmail.com>
Reviewed-by: Jiri Slaby <jirislaby@kernel.org>
Link: https://lore.kernel.org/r/20221123130500.1030189-8-gsomlo@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial')
-rw-r--r-- | drivers/tty/serial/liteuart.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/serial/liteuart.c b/drivers/tty/serial/liteuart.c index 81a86c5eb393..c90ab65fbdcf 100644 --- a/drivers/tty/serial/liteuart.c +++ b/drivers/tty/serial/liteuart.c @@ -82,7 +82,7 @@ static void liteuart_timer(struct timer_list *t) port->icount.rx++; /* necessary for RXEMPTY to refresh its value */ - litex_write8(membase + OFF_EV_PENDING, EV_TX | EV_RX); + litex_write8(membase + OFF_EV_PENDING, EV_RX); /* no overflow bits in status */ if (!(uart_handle_sysrq_char(port, ch))) |