From: Pratyush ANAND <[email protected]>

For core 1.94A and latter, specification says to issue DEPCFG with
"Config Action: Modify" for physical endpoint 0/1.

Signed-off-by: Pratyush Anand <[email protected]>
---
 drivers/usb/dwc3/gadget.c |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
index 0ead4cd..e582a10 100644
--- a/drivers/usb/dwc3/gadget.c
+++ b/drivers/usb/dwc3/gadget.c
@@ -442,8 +442,12 @@ static int dwc3_gadget_set_ep_config(struct dwc3 *dwc, 
struct dwc3_ep *dep,
                | DWC3_DEPCFG_MAX_PACKET_SIZE(usb_endpoint_maxp(desc))
                | DWC3_DEPCFG_BURST_SIZE(dep->endpoint.maxburst);
 
-       if (ignore)
-               params.param0 |= DWC3_DEPCFG_IGN_SEQ_NUM;
+       if (ignore) {
+               if (dwc->revision < DWC3_REVISION_194A)
+                       params.param0 |= DWC3_DEPCFG_IGN_SEQ_NUM;
+               else
+                       params.param0 |= DWC3_DEPCFG_ACTION_MODIFY;
+       }
 
        params.param1 = DWC3_DEPCFG_XFER_COMPLETE_EN
                | DWC3_DEPCFG_XFER_NOT_READY_EN;
-- 
1.7.5.4

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to