linux/drivers/tty
Johan Hovold 23ee4a2566 serial: qcom-geni: fix dma rx cancellation
Make sure to wait for the DMA transfer to complete when cancelling the
rx command on stop_rx(). This specifically prevents the DMA completion
interrupt from firing after rx has been restarted, something which can
lead to an IOMMU fault and hosed rx when the interrupt handler unmaps
the DMA buffer for the new command:

	qcom_geni_serial 988000.serial: serial engine reports 0 RX bytes in!
	arm-smmu 15000000.iommu: FSR    = 00000402 [Format=2 TF], SID=0x563
	arm-smmu 15000000.iommu: FSYNR0 = 00210013 [S1CBNDX=33 WNR PLVL=3]
	Bluetooth: hci0: command 0xfc00 tx timeout
	Bluetooth: hci0: Reading QCA version information failed (-110)

Also add the missing state machine reset which is needed in case
cancellation fails.

Fixes: 2aaa43c707 ("tty: serial: qcom-geni-serial: add support for serial engine DMA")
Cc: stable@vger.kernel.org      # 6.3
Cc: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Signed-off-by: Johan Hovold <johan+linaro@kernel.org>
Link: https://lore.kernel.org/r/20241009145110.16847-5-johan+linaro@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-10-11 08:39:23 +02:00
..
hvc tty: hvc: convert comma to semicolon 2024-09-03 10:47:56 +02:00
ipwireless tty: ipwireless: remove unused ipw_dev::attribute_memory 2023-11-23 19:16:03 +00:00
serdev serdev: Use of_property_present() 2024-08-07 13:08:14 +02:00
serial serial: qcom-geni: fix dma rx cancellation 2024-10-11 08:39:23 +02:00
vt vt: prevent kernel-infoleak in con_font_get() 2024-10-11 08:27:36 +02:00
amiserial.c tty: add missing MODULE_DESCRIPTION() macros 2024-06-24 16:10:11 +02:00
ehv_bytechan.c tty: ehv_bytechan: convert to u8 and size_t 2023-12-08 12:02:37 +01:00
goldfish.c tty: add missing MODULE_DESCRIPTION() macros 2024-06-24 16:10:11 +02:00
Kconfig vt: remove superfluous CONFIG_HW_CONSOLE 2024-01-27 19:03:51 -08:00
Makefile
mips_ejtag_fdc.c tty: mips_ejtag_fdc: Fix passing incompatible pointer type warning 2024-02-23 10:14:16 +01:00
moxa.c tty: moxa: convert to u8 and size_t 2023-12-08 12:02:38 +01:00
mxser.c mxser: convert comma to semicolon 2024-09-03 10:47:47 +02:00
n_gsm.c tty: n_gsm: Fix use-after-free in gsm_cleanup_mux 2024-10-11 08:28:17 +02:00
n_hdlc.c tty: add missing MODULE_DESCRIPTION() macros 2024-06-24 16:10:11 +02:00
n_null.c tty: ldops: unify to u8 2023-08-11 21:12:47 +02:00
n_tty.c tty: n_tty: Fix buffer offsets when lookahead is used 2024-06-04 14:07:27 +02:00
nozomi.c tty: nozomi: convert to u8 and size_t 2023-12-08 12:02:38 +01:00
pty.c tty: make tty_operations::write()'s count size_t 2023-08-11 21:12:46 +02:00
rpmsg_tty.c tty: make tty_operations::write()'s count size_t 2023-08-11 21:12:46 +02:00
synclink_gt.c tty: add missing MODULE_DESCRIPTION() macros 2024-06-24 16:10:11 +02:00
sysrq.c Linux 6.11-rc1 2024-07-30 09:30:11 -10:00
tty_audit.c tty: audit: unify to u8 2023-08-11 21:12:46 +02:00
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 [tree-wide] finally take no_llseek out 2024-09-27 08:18:43 -07:00
tty_ioctl.c tty: allow TIOCSLCKTRMIOS with CAP_CHECKPOINT_RESTORE 2023-12-15 14:20:03 +01:00
tty_jobctrl.c tty: tty_jobctrl: fix pid memleak in disassociate_ctty() 2023-09-18 11:14:43 +02:00
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 tty: switch tty_port::xmit_* to u8 2023-12-08 12:02:37 +01:00
tty.h tty: convert THROTTLE constants into enum 2023-10-03 14:31:16 +02:00
ttynull.c tty: add missing MODULE_DESCRIPTION() macros 2024-06-24 16:10:11 +02:00
vcc.c tty: vcc: Add check for kstrdup() in vcc_probe() 2023-09-18 11:14:42 +02:00