summaryrefslogtreecommitdiff
path: root/drivers/usb/dwc2/core.h
diff options
context:
space:
mode:
authorVardan Mikayelyan <mvardan@synopsys.com>2016-05-26 04:07:05 +0300
committerFelipe Balbi <felipe.balbi@linux.intel.com>2016-06-21 10:49:21 +0300
commit92d1635d781ac17fc7d886b0c126838083f3c2b9 (patch)
tree3ac16508dc525f1eb41fd4114a848ebe350de8c5 /drivers/usb/dwc2/core.h
parent6b58cb07a850f9b6d348feb2455b2c264a515f4a (diff)
downloadlinux-92d1635d781ac17fc7d886b0c126838083f3c2b9.tar.xz
usb: dwc2: gadget: Add dwc2_gadget_incr_frame_num()
Increases and checks targeted frame number of current ep if overrun happened, sets flag and masks with DSTS_SOFFN_LIMIT Added following fields to struct dwc2_hsotg_ep -target_frame: Targeted frame num to setup next ISOC transfer -frame_overrun: Indicates SOF number overrun in DSTS 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>
Diffstat (limited to 'drivers/usb/dwc2/core.h')
-rw-r--r--drivers/usb/dwc2/core.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/usb/dwc2/core.h b/drivers/usb/dwc2/core.h
index dec0b21fc626..55160992b181 100644
--- a/drivers/usb/dwc2/core.h
+++ b/drivers/usb/dwc2/core.h
@@ -177,6 +177,8 @@ struct dwc2_hsotg_req;
* @fifo_load: The amount of data loaded into the FIFO (periodic IN)
* @last_load: The offset of data for the last start of request.
* @size_loaded: The last loaded size for DxEPTSIZE for periodic IN
+ * @target_frame: Targeted frame num to setup next ISOC transfer
+ * @frame_overrun: Indicates SOF number overrun in DSTS
*
* This is the driver's state for each registered enpoint, allowing it
* to keep track of transactions that need doing. Each endpoint has a
@@ -214,6 +216,9 @@ struct dwc2_hsotg_ep {
unsigned int isochronous:1;
unsigned int send_zlp:1;
unsigned int has_correct_parity:1;
+ unsigned int target_frame;
+#define TARGET_FRAME_INITIAL 0xFFFFFFFF
+ bool frame_overrun;
char name[10];
};