diff options
-rw-r--r-- | drivers/hid/usbhid/hid-core.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c index 3ff74685875d..6e7393460ead 100644 --- a/drivers/hid/usbhid/hid-core.c +++ b/drivers/hid/usbhid/hid-core.c | |||
@@ -877,6 +877,7 @@ fail: | |||
877 | usb_free_urb(usbhid->urbin); | 877 | usb_free_urb(usbhid->urbin); |
878 | usb_free_urb(usbhid->urbout); | 878 | usb_free_urb(usbhid->urbout); |
879 | usb_free_urb(usbhid->urbctrl); | 879 | usb_free_urb(usbhid->urbctrl); |
880 | kfree(usbhid); | ||
880 | fail_no_usbhid: | 881 | fail_no_usbhid: |
881 | hid_free_buffers(dev, hid); | 882 | hid_free_buffers(dev, hid); |
882 | hid_free_device(hid); | 883 | hid_free_device(hid); |
@@ -912,6 +913,7 @@ static void hid_disconnect(struct usb_interface *intf) | |||
912 | usb_free_urb(usbhid->urbin); | 913 | usb_free_urb(usbhid->urbin); |
913 | usb_free_urb(usbhid->urbctrl); | 914 | usb_free_urb(usbhid->urbctrl); |
914 | usb_free_urb(usbhid->urbout); | 915 | usb_free_urb(usbhid->urbout); |
916 | kfree(usbhid); | ||
915 | 917 | ||
916 | hid_free_buffers(hid_to_usb_dev(hid), hid); | 918 | hid_free_buffers(hid_to_usb_dev(hid), hid); |
917 | hid_free_device(hid); | 919 | hid_free_device(hid); |