mirror-linux/drivers/tty
Johan Hovold 947cc4ecc0 serial: qcom-geni: fix soft lockup on sw flow control and suspend
The stop_tx() callback is used to implement software flow control and
must not discard data as the Qualcomm GENI driver is currently doing
when there is an active TX command.

Cancelling an active command can also leave data in the hardware FIFO,
which prevents the watermark interrupt from being enabled when TX is
later restarted. This results in a soft lockup and is easily triggered
by stopping TX using software flow control in a serial console but this
can also happen after suspend.

Fix this by only stopping any active command, and effectively clearing
the hardware fifo, when shutting down the port. When TX is later
restarted, a transfer command may need to be issued to discard any stale
data that could prevent the watermark interrupt from firing.

Fixes: c4f528795d ("tty: serial: msm_geni_serial: Add serial driver support for GENI based QUP")
Cc: stable@vger.kernel.org	# 4.17
Signed-off-by: Johan Hovold <johan+linaro@kernel.org>
Link: https://lore.kernel.org/r/20240704101805.30612-2-johan+linaro@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-07-04 12:30:30 +02:00
..
hvc TTY/Serial changes for 6.10-rc1 2024-05-22 11:53:02 -07:00
ipwireless
serdev serdev: make serdev_bus_type const 2024-02-06 14:35:38 +00:00
serial serial: qcom-geni: fix soft lockup on sw flow control and suspend 2024-07-04 12:30:30 +02:00
vt TTY/Serial changes for 6.10-rc1 2024-05-22 11:53:02 -07:00
Kconfig
Makefile
amiserial.c serial: ami: Mark driver struct with __refdata to prevent section mismatch 2024-04-09 15:50:22 +02:00
ehv_bytechan.c
goldfish.c tty: goldfish: Convert to platform remove callback returning void 2024-02-19 09:40:50 +01:00
mips_ejtag_fdc.c tty: mips_ejtag_fdc: Fix passing incompatible pointer type warning 2024-02-23 10:14:16 +01:00
moxa.c
mxser.c tty: mxser: Remove __counted_by from mxser_board.ports[] 2024-06-28 08:54:56 -07:00
n_gsm.c TTY/Serial fixes for 6.10-rc1 2024-05-24 08:38:28 -07:00
n_hdlc.c
n_null.c
n_tty.c tty: n_tty: Fix buffer offsets when lookahead is used 2024-06-04 14:07:27 +02:00
nozomi.c
pty.c
rpmsg_tty.c
synclink_gt.c
sysrq.c tty/sysrq: Replay kernel log messages on consoles via sysrq 2024-04-11 14:22:52 +02:00
tty.h
tty_audit.c
tty_baudrate.c
tty_buffer.c tty: Don't include tty_buffer.h in tty.h 2024-02-18 18:59:59 +01:00
tty_io.c
tty_ioctl.c
tty_jobctrl.c
tty_ldisc.c tty: add the option to have a tty reject a new ldisc 2024-05-04 18:45:11 +02:00
tty_ldsem.c
tty_mutex.c
tty_port.c
ttynull.c
vcc.c