[PATCH] USB: serial: ti_usb_3410_5052: fix read urb resubmission at open
From: YuanZhe Liu
Date: Mon Nov 30 2026 - 10:01:50 EST
A port that has been throttled keeps TI_READ_URB_STOPPED across close as
the read urb state is never reset.
During the next open(), ti_set_termios() is called before the port has
been started and would therefore restart the read urb, which is then
submitted a second time at the end of open():
URB 00000000b0fe02b4 submitted while active
WARNING: CPU: 0 PID: 1840 at drivers/usb/core/urb.c:379 usb_submit_urb+0x14c5/0x1790
ti_usb_3410_5052_2 ttyUSB0: ti_open - submit read urb failed, -16
The failed submit also leaves the read urb running after open() returns
and, as the port is never marked initialized, close() will not kill it.
Fix this by resetting the read urb state before termios is applied so
that the read urb is only submitted once, after the port has been
started.
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Cc: stable@xxxxxxxxxxxxxxx # 2.6.12
Co-developed-by: Bin Yu <byu@xxxxxxxxxxxxx>
Signed-off-by: Bin Yu <byu@xxxxxxxxxxxxx>
Co-developed-by: Cheng Wen <wencheng@xxxxxxxxxxxxx>
Signed-off-by: Cheng Wen <wencheng@xxxxxxxxxxxxx>
Signed-off-by: YuanZhe Liu <25031212351@xxxxxxxxxxxxxxxxx>
---
drivers/usb/serial/ti_usb_3410_5052.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/usb/serial/ti_usb_3410_5052.c b/drivers/usb/serial/ti_usb_3410_5052.c
index b3f00e315815..c71f1feac588 100644
--- a/drivers/usb/serial/ti_usb_3410_5052.c
+++ b/drivers/usb/serial/ti_usb_3410_5052.c
@@ -653,6 +653,12 @@ static int ti_open(struct tty_struct *tty, struct usb_serial_port *port)
if (mutex_lock_interruptible(&tdev->td_open_close_lock))
return -ERESTARTSYS;
+ /*
+ * The read urb is only submitted after the port has been started;
+ * make sure termios processing below does not restart it.
+ */
+ tport->tp_read_urb_state = TI_READ_URB_RUNNING;
+
tport->tp_msr = 0;
tport->tp_shadow_mcr |= (TI_MCR_RTS | TI_MCR_DTR);
--
2.34.1