usb: dwc2: gadget: handle reset interrupt before endpoint interrupts
authorMian Yousaf Kaukab <yousaf.kaukab@intel.com>
Tue, 29 Sep 2015 10:08:29 +0000 (12:08 +0200)
committerFelipe Balbi <balbi@ti.com>
Thu, 1 Oct 2015 17:40:27 +0000 (12:40 -0500)
commit8fc37b82a4a43f63e3464e5d02578ea988cb5c01
tree58c042f0f5270162ce6129b6b39451b471c531aa
parent61f7223bf14689382fdf36b7580f206745c2409a
usb: dwc2: gadget: handle reset interrupt before endpoint interrupts

If system is loaded, reset, enum-done and setup interrupts can occur
at the same time. Current interrupt handling sequence will handle
setup packet's interrupt before handling reset interrupt. Which will
break the enumeration process. Correct sequence is to handle reset,
enum-done and then any other endpoint interrupts.

Signed-off-by: Mian Yousaf Kaukab <yousaf.kaukab@intel.com>
Tested-by: Robert Baldyga <r.baldyga@samsung.com>
Tested-by: Dinh Nguyen <dinguyen@opensource.altera.com>
Tested-by: John Youn <johnyoun@synopsys.com>
Acked-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/dwc2/gadget.c