usb: dwc3: Add new updates for DWC_usb31
Subsystems (2)
cover usb: dwc3: Add new updates for DWC_usb31
This patch series adds new updates and some fixes for DWC_usb31.
Thinh Nguyen (15):
usb: dwc3: Device SoftReset PHY synchonization delay
usb: core: urb: Check SSP isoc ep comp descriptor
usb: dwc3: Update DWC_usb31 GTXFIFOSIZ reg fields
usb: dwc3: Check IP revision for GTXFIFOSIZ
usb: dwc3: Add DWC_usb31 GRXTHRCFG bit fields
usb: dwc3: gadget: Check IP revision for GRXTHRCFG
usb: dwc3: Add DWC_usb31 GTXTHRCFG reg fields
usb: dwc3: Make RX/TX threshold configurable
usb: dwc3: Check for ESS TX/RX threshold config
usb: dwc3: gadget: Set maxpacket size for ep0 IN
usb: dwc3: ep0: Reset TRB counter for ep0 IN
usb: dwc3: Dump LSP and BMU debug info
usb: dwc3: Track DWC_usb31 VERSIONTYPE
usb: dwc3: Add disabling of start_transfer failure quirk
usb: dwc3: Add workaround for isoc start transfer failure
Documentation/devicetree/bindings/usb/dwc3.txt | 9 ++ drivers/usb/core/urb.c | 8 + drivers/usb/dwc3/core.c | 74 ++++++++- drivers/usb/dwc3/core.h | 57 +++++++ drivers/usb/dwc3/debugfs.c | 5 + drivers/usb/dwc3/ep0.c | 7 +- drivers/usb/dwc3/gadget.c | 202 ++++++++++++++++++++++++- 7 files changed, 353 insertions(+), 9 deletions(-)
Signature · 6 lines
2.11.0 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): cover.1515182391.git.thinhn-HKixBCOQz3hWk0Htik3J/[email protected]
PATCH 8/15 usb: dwc3: Make RX/TX threshold configurable
DWC_usb31 periodic transfer at 48K+ bytes per interval may need modification to the TX/RX packet threshold to achieve optimal result. Add properties to make it configurable.
--- Documentation/devicetree/bindings/usb/dwc3.txt | 6 ++++++ 1 file changed, 6 insertions(+)
Documentation/devicetree/bindings/usb/dwc3.txt +6 -0
@@ -55,6 +55,12 @@ Optional properties: - snps,quirk-frame-length-adjustment: Value for GFLADJ_30MHZ field of GFLADJ register for post-silicon frame length adjustment when the fladj_30mhz_sdbnd signal is invalid or incorrect. + - snps,rx_thr_sel_prd: set to enable periodic ESS RX packet threshold. + - snps,rx_thr_num_pkt_prd: periodic ESS RX packet threshold count. + - snps,rx_max_burst_prd: Max periodic ESS RX burst size. + - snps,tx_thr_sel_prd: set to enable periodic ESS TX packet threshold. + - snps,tx_thr_num_pkt_prd: periodic ESS TX packet threshold count. + - snps,tx_max_burst_prd: Max periodic ESS TX burst size. - <DEPRECATED> tx-fifo-resize: determines if the FIFO *has* to be reallocated.
Signature · 6 lines
2.11.0 -- 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
A message that is not in the archive (sent off-list or not yet received): 8446dc260efb993507a219ae11815607b8e58027.1515182391.git.thinhn-HKixBCOQz3hWk0Htik3J/[email protected]
Re: [PATCH 08/15] usb: dwc3: Make RX/TX threshold configurable
Quoted 3 lines · Thinh Nguyen
DWC_usb31periodic transfer at 48K+ bytes per interval may need modification to the TX/RX packet threshold to achieve optimal result. Add properties to make it configurable.
I tend to think these should all be implied by the SoC specific compatible string if they need to be tuned.
Quoted 12 lines
Cc John Youn <johnyoun-HKixBCOQz3hWk0Htik3J/[email protected]>--- Documentation/devicetree/bindings/usb/dwc3.txt | 6 ++++++ 1 file changed, 6 insertions(+)Documentation/devicetree/bindings/usb/dwc3.txt +0
-0
Documentation/devicetree/bindings/usb/dwc3.txt Optional properties: · line 58
Quoted 4 lines
Documentation/devicetree/bindings/usb/dwc3.txt +1
-0@@ -55,6 +55,12 @@ Optional properties: - snps,quirk-frame-length-adjustment: Value for GFLADJ_30MHZ field of GFLADJ register for post-silicon frame length adjustment when the fladj_30mhz_sdbnd signal is invalid or incorrect. + - snps,rx_thr_sel_prd: set to enable periodic ESS RX packet threshold.
Isn't the next property being present sufficient to enable this or not?
Documentation/devicetree/bindings/usb/dwc3.txt Optional properties: · line 61
Quoted 3 lines
Documentation/devicetree/bindings/usb/dwc3.txt +3
-0+ - snps,rx_thr_num_pkt_prd: periodic ESS RX packet threshold count. + - snps,rx_max_burst_prd: Max periodic ESS RX burst size. + - snps,tx_thr_sel_prd: set to enable periodic ESS TX packet threshold.
ditto
Documentation/devicetree/bindings/usb/dwc3.txt Optional properties: · line 63
Quoted 2 lines
Documentation/devicetree/bindings/usb/dwc3.txt +2
-0+ - snps,tx_thr_num_pkt_prd: periodic ESS TX packet threshold count. + - snps,tx_max_burst_prd: Max periodic ESS TX burst size.
Don't use '_' in property names.
Quoted 6 lines
Documentation/devicetree/bindings/usb/dwc3.txt +0
-0- <DEPRECATED> tx-fifo-resize: determines if the FIFO *has* to be reallocated.Signature · 1 line
2.11.0
--
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
Re: [PATCH 08/15] usb: dwc3: Make RX/TX threshold configurable
Hi,
Quoted 15 lines · Rob Herring
Quoted 3 lines · Thinh Nguyen
DWC_usb31periodic transfer at 48K+ bytes per interval may need modification to the TX/RX packet threshold to achieve optimal result. Add properties to make it configurable.I tend to think these should all be implied by the SoC specific compatible string if they need to be tuned.
Quoted 7 lines
Cc John Youn <johnyoun-HKixBCOQz3hWk0Htik3J/[email protected]>--- Documentation/devicetree/bindings/usb/dwc3.txt | 6 ++++++ 1 file changed, 6 insertions(+)
Quoted 11 lines
Documentation/devicetree/bindings/usb/dwc3.txt Optional properties: · line 58
Quoted 9 lines
Documentation/devicetree/bindings/usb/dwc3.txt +1
-0@@ -55,6 +55,12 @@ Optional properties: - snps,quirk-frame-length-adjustment: Value for GFLADJ_30MHZ field of GFLADJ register for post-silicon frame length adjustment when the fladj_30mhz_sdbnd signal is invalid or incorrect. + - snps,rx_thr_sel_prd: set to enable periodic ESS RX packet threshold.Isn't the next property being present sufficient to enable this or not?
Yes, we can do that. Actually, both settings must be set to enable the periodic TX/RX threshold.
Quoted 11 lines
Documentation/devicetree/bindings/usb/dwc3.txt Optional properties: · line 61
Quoted 4 lines
Documentation/devicetree/bindings/usb/dwc3.txt +3
-0+ - snps,rx_thr_num_pkt_prd: periodic ESS RX packet threshold count. + - snps,rx_max_burst_prd: Max periodic ESS RX burst size. + - snps,tx_thr_sel_prd: set to enable periodic ESS TX packet threshold.ditto
Documentation/devicetree/bindings/usb/dwc3.txt Optional properties: · line 63
Quoted 2 lines
Documentation/devicetree/bindings/usb/dwc3.txt +2
-0+ - snps,tx_thr_num_pkt_prd: periodic ESS TX packet threshold count. + - snps,tx_max_burst_prd: Max periodic ESS TX burst size.Don't use '_' in property names.
I'll make the change.
Quoted 8 lines
Quoted 7 lines
Documentation/devicetree/bindings/usb/dwc3.txt +0
-0- <DEPRECATED> tx-fifo-resize: determines if the FIFO *has* to be reallocated.Signature · 1 line
2.11.0
Thanks,
Thinh
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
PATCH 14/15 usb: dwc3: Add disabling of start_transfer failure quirk
In reply to a message not in the archiveIn DWC_usb31 version 1.70a-ea06 and prior needs a SW workaround for isoc START TRANSFER command failure. However, some affected versions may have RTL patches to fix this without a SW workaround. Add this quirk to disable the SW workaround when it is not needed.
Synopsys STAR 9001202023: Wrong microframe number for isochronous IN endpoints.
--- Documentation/devicetree/bindings/usb/dwc3.txt | 3 +++ 1 file changed, 3 insertions(+)
Documentation/devicetree/bindings/usb/dwc3.txt +3 -0
@@ -15,6 +15,9 @@ Optional properties: - phys: from the *Generic PHY* bindings - phy-names: from the *Generic PHY* bindings; supported names are "usb2-phy" or "usb3-phy". + - snps,dis_start_transfer_quirk: when set, disable isoc START TRANSFER command + failure SW work-around for DWC_usb31 version 1.70a-ea06 + and prior. - snps,usb3_lpm_capable: determines if platform is USB3 LPM capable - snps,disable_scramble_quirk: true when SW should disable data scrambling. Only really useful for FPGA builds.
Signature · 6 lines
2.11.0 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 3c63b5f97343d276049e1d59ef2371160004b137.1515182391.git.thinhn-HKixBCOQz3hWk0Htik3J/[email protected]
Re: [PATCH 14/15] usb: dwc3: Add disabling of start_transfer failure quirk
Quoted 4 lines · Thinh Nguyen
In
DWC_usb31version 1.70a-ea06 and prior needs a SW workaround for isoc START TRANSFER command failure. However, some affected versions may have RTL patches to fix this without a SW workaround. Add this quirk to disable the SW workaround when it is not needed.
I really think this one should be implied by compatible strings.
Quoted 26 lines
Synopsys STAR 9001202023: Wrong microframe number for isochronous IN endpoints.
Cc John Youn <johnyoun-HKixBCOQz3hWk0Htik3J/[email protected]>--- Documentation/devicetree/bindings/usb/dwc3.txt | 3 +++ 1 file changed, 3 insertions(+)Documentation/devicetree/bindings/usb/dwc3.txt +3
-0@@ -15,6 +15,9 @@ Optional properties: - phys: from the *Generic PHY* bindings - phy-names: from the *Generic PHY* bindings; supported names are "usb2-phy" or "usb3-phy". + - snps,dis_start_transfer_quirk: when set, disable isoc START TRANSFER command + failure SW work-around for DWC_usb31 version 1.70a-ea06 + and prior. - snps,usb3_lpm_capable: determines if platform is USB3 LPM capable - snps,disable_scramble_quirk: true when SW should disable data scrambling. Only really useful for FPGA builds.Signature · 1 line
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH 14/15] usb: dwc3: Add disabling of start_transfer failure quirk
Hi,
Quoted 7 lines · Rob Herring
Quoted 4 lines · Thinh Nguyen
In
DWC_usb31version 1.70a-ea06 and prior needs a SW workaround for isoc START TRANSFER command failure. However, some affected versions may have RTL patches to fix this without a SW workaround. Add this quirk to disable the SW workaround when it is not needed.I really think this one should be implied by compatible strings.
won't work for dwc3. Core driver has a single compatible string, also this wouldn't work for PCI-based implementations.
Signature · 1 line
balbi
A message that is not in the archive (sent off-list or not yet received): 87incbzaia.fsf-VuQAYsv1563Yd54FQh9/[email protected]
Re: [PATCH 14/15] usb: dwc3: Add disabling of start_transfer failure quirk
Quoted 10 lines · Felipe Balbi
Hi,
Quoted 6 lines · Rob Herring
Quoted 4 lines · Thinh Nguyen
In
DWC_usb31version 1.70a-ea06 and prior needs a SW workaround for isoc START TRANSFER command failure. However, some affected versions may have RTL patches to fix this without a SW workaround. Add this quirk to disable the SW workaround when it is not needed.
Quoted 4 lines
Quoted 1 line
I really think this one should be implied by compatible strings.
won't work for dwc3. Core driver has a single compatible string, also this wouldn't work for PCI-based implementations.
Then you will have to look at the parent node (this is why the way DWC3 was split is wrong) or make the compatible strings more specific. That is the purpose of compatible strings.
For PCI, don't you have different VID/PIDs? If not how would quirks work for non-DT systems.
Rob
--
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