diff options
author | Jianqiang Tang <jianqiang.tang@intel.com> | 2016-01-20 14:09:39 +0800 |
---|---|---|
committer | Felipe Balbi <balbi@kernel.org> | 2016-02-03 23:58:20 +0200 |
commit | 6a4290cc28be12d72d50644bd4bda1aede37cd41 (patch) | |
tree | d60be6849e03b3c3f119d3259cab523c62e46bf9 | |
parent | a55f6286575863ebfa5577d4d3bb3b6f1dbd45ec (diff) | |
download | blackbird-op-linux-6a4290cc28be12d72d50644bd4bda1aede37cd41.tar.gz blackbird-op-linux-6a4290cc28be12d72d50644bd4bda1aede37cd41.zip |
usb: dwc3: gadget: set the OTG flag in dwc3 gadget driver.
This patch is needed in order to pass one test case
defined in the OTG Automated Compliance Test specification.
Specification location:
http://www.usb.org/developers/onthego/otgeh_compliance_plan_1_2.pdf
This test case uses PET Tool, and PET Tool is one USB hardware
equipment provided by MQP Electronics.
Test case id is 6.8.3 B-UUT Bypass Capacitance.
We must set this otg flag in order to be able to return OTG
descriptor during enumeration, otherwise this test case with
failed with below error: "Get OTG descriptor request stalled".
Signed-off-by: Jianqiang Tang <jianqiang.tang@intel.com>
Signed-off-by: Felipe Balbi <balbi@kernel.org>
-rw-r--r-- | drivers/usb/dwc3/gadget.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c index af023a81a0b0..7d1dd82a95ac 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -2789,6 +2789,7 @@ int dwc3_gadget_init(struct dwc3 *dwc) dwc->gadget.speed = USB_SPEED_UNKNOWN; dwc->gadget.sg_supported = true; dwc->gadget.name = "dwc3-gadget"; + dwc->gadget.is_otg = dwc->dr_mode == USB_DR_MODE_OTG; /* * FIXME We might be setting max_speed to <SUPER, however versions |