aboutsummaryrefslogtreecommitdiffstats
diff options
authorJohan Hovold <johan@kernel.org>2025-04-24 09:44:48 +0200
committerJohan Hovold <johan@kernel.org>2025-05-05 14:25:59 +0200
commit692a497eb748fa597918f1faa11e77465b23cc00 (patch)
treeb2e2123291b6b88d1b76e7dce8fc898c843bc986
parentb4432656b36e5cc1d50a1f2dc15357543add530e (diff)
downloadusb-serial-usb-next.tar.gz
USB: serial: ti_usb_3410_5052: drop bogus read urb checkusb-next
The read urb pointer is dereferenced before checking that it is non-NULL during open(), but no check is needed as the existence of a bulk in endpoint is verified during attach() since commit ef079936d3cd ("USB: serial: ti_usb_3410_5052: fix NULL-deref at open"). Drop the bogus read urb sanity check. Signed-off-by: Johan Hovold <johan@kernel.org>
-rw-r--r--drivers/usb/serial/ti_usb_3410_5052.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/usb/serial/ti_usb_3410_5052.c b/drivers/usb/serial/ti_usb_3410_5052.c
index a0c244bc77c094..d671189ecee279 100644
--- a/drivers/usb/serial/ti_usb_3410_5052.c
+++ b/drivers/usb/serial/ti_usb_3410_5052.c
@@ -729,11 +729,6 @@ static int ti_open(struct tty_struct *tty, struct usb_serial_port *port)
/* start read urb */
urb = port->read_urb;
- if (!urb) {
- dev_err(&port->dev, "%s - no read urb\n", __func__);
- status = -EINVAL;
- goto unlink_int_urb;
- }
tport->tp_read_urb_state = TI_READ_URB_RUNNING;
urb->context = tport;
status = usb_submit_urb(urb, GFP_KERNEL);