]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
usb: gadget: midi: free hs descriptors
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>
Mon, 22 Oct 2012 20:15:02 +0000 (22:15 +0200)
committerBen Hutchings <ben@decadent.org.uk>
Thu, 3 Jan 2013 03:33:00 +0000 (03:33 +0000)
commit d185039f7982eb82cf8d03b6fb6689587ca5af24 upstream.

The HS descriptors are only created if HS is supported by the UDC but we
never free them.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
drivers/usb/gadget/f_midi.c

index 3797b3d6c622bd49ff709b33303a86e323294c44..dfd7b98f3d2710138ca07def74ec29c4e4ccd095 100644 (file)
@@ -416,6 +416,7 @@ static void f_midi_unbind(struct usb_configuration *c, struct usb_function *f)
        midi->id = NULL;
 
        usb_free_descriptors(f->descriptors);
+       usb_free_descriptors(f->hs_descriptors);
        kfree(midi);
 }