From: yangkai Date: Fri, 30 Mar 2012 04:03:43 +0000 (+0800) Subject: fix usb endpoint bug X-Git-Tag: firefly_0821_release~9554 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=27fc6acc7957287b1a4e96dfe84f917dff16f53c;p=firefly-linux-kernel-4.4.55.git fix usb endpoint bug --- diff --git a/drivers/usb/dwc_otg/dwc_otg_pcd.c b/drivers/usb/dwc_otg/dwc_otg_pcd.c index 9732965493f6..76099b51e4a5 100755 --- a/drivers/usb/dwc_otg/dwc_otg_pcd.c +++ b/drivers/usb/dwc_otg/dwc_otg_pcd.c @@ -1478,6 +1478,8 @@ void dwc_otg_pcd_reinit(dwc_otg_pcd_t *_pcd) * here? Before EP type is set? */ ep->ep.maxpacket = MAX_PACKET_SIZE; + + INIT_LIST_HEAD (&ep->queue); /** * @yk@rk 20120329 @@ -1489,7 +1491,6 @@ void dwc_otg_pcd_reinit(dwc_otg_pcd_t *_pcd) #endif list_add_tail (&ep->ep.ep_list, &_pcd->gadget.ep_list); - INIT_LIST_HEAD (&ep->queue); } hwcfg1 >>= 2; } @@ -1539,6 +1540,8 @@ void dwc_otg_pcd_reinit(dwc_otg_pcd_t *_pcd) */ ep->ep.maxpacket = MAX_PACKET_SIZE; + INIT_LIST_HEAD (&ep->queue); + /** * @yk@rk 20120329 * EP8&EP9 of rk30 are IN&OUT ep, we use ep9 as IN EP default @@ -1549,7 +1552,6 @@ void dwc_otg_pcd_reinit(dwc_otg_pcd_t *_pcd) #endif list_add_tail (&ep->ep.ep_list, &_pcd->gadget.ep_list); - INIT_LIST_HEAD (&ep->queue); } hwcfg1 >>= 2; }