]> git.baikalelectronics.ru Git - kernel.git/commit
usb: dwc2: gadget: Add Incomplete ISO IN/OUT Interrupt handlers
authorVardan Mikayelyan <mvardan@synopsys.com>
Thu, 26 May 2016 01:07:17 +0000 (18:07 -0700)
committerFelipe Balbi <felipe.balbi@linux.intel.com>
Tue, 21 Jun 2016 07:50:00 +0000 (10:50 +0300)
commit4d84e16efef4dbc35d66812f21af2a0fa8299426
tree539aa6bfd43d28496359f7c199ec85a8a22c1841
parentf8f8d11625a2900ef627ca1490e2682a583e0ac5
usb: dwc2: gadget: Add Incomplete ISO IN/OUT Interrupt handlers

Incomplete ISO IN interrupt indicates one of the following conditions
occurred while transmitting an ISOC transaction.
- Corrupted IN Token for ISOC EP.
- Packet not complete in FIFO.

Incomplete ISO OUT indicates that there is at least one isochronous OUT
endpoint on which the transfer is not completed in the current
microframe.

The following actions will be taken:

In case of EP-IN
- Determine the EP
- Disable EP directly from this handler; when "Endpoint Disabled"
  interrupt is received flush FIFO

In case of EP-OUT
- Determine the EP
- If target frame elapsed set DCTL_SGOUTNAK, unmask GOUTNAKEFF and
  proceed as described in section 7.5.1 of DWC-HSOTG Programming Guide

Also added dwc2_gadget_target_frame_elapsed() helper function which
will be used in Incomplete ISO IN/OUT Interrupt handlers.

Tested-by: John Keeping <john@metanate.com>
Signed-off-by: Vardan Mikayelyan <mvardan@synopsys.com>
Signed-off-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
drivers/usb/dwc2/gadget.c