aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial
diff options
context:
space:
mode:
authorJohan Hovold <jhovold@gmail.com>2012-11-18 07:23:28 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-11-21 16:33:55 -0500
commit70f9bf65a4413cb3c7405b2078efb8b27acc7222 (patch)
treebfe2422d5f704dd348190b497a095b421061c015 /drivers/usb/serial
parenta0a5fd92a4d62506cb5c6fa64fb25653dda2cf09 (diff)
USB: opticon: move read-urb deallocation to release
Move read-urb deallocation from disconnect to release. Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/serial')
-rw-r--r--drivers/usb/serial/opticon.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/serial/opticon.c b/drivers/usb/serial/opticon.c
index e275abb9a1ec..77700b0720c6 100644
--- a/drivers/usb/serial/opticon.c
+++ b/drivers/usb/serial/opticon.c
@@ -523,13 +523,13 @@ static void opticon_disconnect(struct usb_serial *serial)
523 struct opticon_private *priv = usb_get_serial_data(serial); 523 struct opticon_private *priv = usb_get_serial_data(serial);
524 524
525 usb_kill_urb(priv->bulk_read_urb); 525 usb_kill_urb(priv->bulk_read_urb);
526 usb_free_urb(priv->bulk_read_urb);
527} 526}
528 527
529static void opticon_release(struct usb_serial *serial) 528static void opticon_release(struct usb_serial *serial)
530{ 529{
531 struct opticon_private *priv = usb_get_serial_data(serial); 530 struct opticon_private *priv = usb_get_serial_data(serial);
532 531
532 usb_free_urb(priv->bulk_read_urb);
533 kfree(priv->bulk_in_buffer); 533 kfree(priv->bulk_in_buffer);
534 kfree(priv); 534 kfree(priv);
535} 535}