Fix for DWC OTG HCD URB Dequeue has NULL URB panic. Thanks Naren

This commit is contained in:
popcornmix
2012-05-15 15:24:40 +01:00
parent c0f45f4859
commit b66b4fe8f3

View File

@@ -761,10 +761,12 @@ static int urb_dequeue(struct usb_hcd *hcd, struct urb *urb, int status)
dump_urb_info(urb, "urb_dequeue");
}
#endif
if(urb->hcpriv != NULL) {
dwc_otg_hcd_urb_dequeue(dwc_otg_hcd, (dwc_otg_hcd_urb_t *)urb->hcpriv);
dwc_free(urb->hcpriv);
urb->hcpriv = NULL;
dwc_free(urb->hcpriv);
}
/* Higher layer software sets URB status. */
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,30))