[PATCH 248/270] USB: mos7840: fix urb leak at release
Herton Ronaldo Krzesinski
herton.krzesinski at canonical.com
Mon Nov 26 16:58:58 UTC 2012
3.5.7u1 -stable review patch. If anyone has any objections, please let me know.
------------------
From: Johan Hovold <jhovold at gmail.com>
commit 65a4cdbb170e4ec1a7fa0e94936d47e24a17b0e8 upstream.
Make sure control urb is freed at release.
Signed-off-by: Johan Hovold <jhovold at gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at linuxfoundation.org>
Signed-off-by: Herton Ronaldo Krzesinski <herton.krzesinski at canonical.com>
---
drivers/usb/serial/mos7840.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c
index 009c1d9..748bc6a 100644
--- a/drivers/usb/serial/mos7840.c
+++ b/drivers/usb/serial/mos7840.c
@@ -2755,6 +2755,7 @@ static void mos7840_release(struct usb_serial *serial)
del_timer_sync(&mos7840_port->led_timer1);
del_timer_sync(&mos7840_port->led_timer2);
}
+ usb_free_urb(mos7840_port->control_urb);
kfree(mos7840_port->ctrl_buf);
kfree(mos7840_port->dr);
kfree(mos7840_port);
--
1.7.9.5
More information about the kernel-team
mailing list