Commit c3e08bc4 authored by Paulo Marques's avatar Paulo Marques Committed by Greg Kroah-Hartman

[PATCH] USB: ftdi_sio.c: not unlinking urb on ftdi_close

This patch fixes a bug in ftdi_sio.c where the driver wouldn't unlink the
read urb if the user application cleared the HUPCL flag on termios->c_cflag.
parent cf2bbebe
...@@ -1362,14 +1362,15 @@ static void ftdi_close (struct usb_serial_port *port, struct file *filp) ...@@ -1362,14 +1362,15 @@ static void ftdi_close (struct usb_serial_port *port, struct file *filp)
if (set_rts(port, LOW) < 0) { if (set_rts(port, LOW) < 0) {
err("Error from RTS LOW urb"); err("Error from RTS LOW urb");
} }
} /* Note change no line if hupcl is off */
/* shutdown our bulk read */ /* shutdown our bulk read */
if (port->read_urb) { if (port->read_urb) {
usb_unlink_urb (port->read_urb); if (usb_unlink_urb (port->read_urb) < 0) {
err("Error unlinking read urb");
}
} }
/* unlink the running write urbs */
} /* Note change no line is hupcl is off */
} /* if (serial->dev) */ } /* if (serial->dev) */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment