2013-01-25 19:06:53 +08:00
|
|
|
synopsys DWC3 CORE
|
|
|
|
|
2015-10-24 03:31:56 +08:00
|
|
|
DWC3- USB3 CONTROLLER. Complies to the generic USB binding properties
|
|
|
|
as described in 'usb/generic.txt'
|
2013-01-25 19:06:53 +08:00
|
|
|
|
|
|
|
Required properties:
|
2013-07-03 02:20:24 +08:00
|
|
|
- compatible: must be "snps,dwc3"
|
2013-01-25 19:06:53 +08:00
|
|
|
- reg : Address and length of the register set for the device
|
|
|
|
- interrupts: Interrupts used by the dwc3 controller.
|
usb: dwc3: support clocks and resets for DWC3 core
Historically, the clocks and resets are handled on the glue layer
side instead of the DWC3 core. For simple cases, dwc3-of-simple.c
takes care of arbitrary number of clocks and resets. The DT node
structure typically looks like as follows:
dwc3-glue {
compatible = "foo,dwc3";
clocks = ...;
resets = ...;
...
dwc3 {
compatible = "snps,dwc3";
...
};
}
By supporting the clocks and the reset in the dwc3/core.c, it will
be turned into a single node:
dwc3 {
compatible = "foo,dwc3", "snps,dwc3";
clocks = ...;
resets = ...;
...
}
This commit adds the binding of clocks and resets specific to this IP.
The number of clocks should generally be the same across SoCs, it is
just some SoCs either tie clocks together or do not provide software
control of some of the clocks.
I took the clock names from the Synopsys datasheet: "ref" (ref_clk),
"bus_early" (bus_clk_early), and "suspend" (suspend_clk).
I found only one reset line in the datasheet, hence the reset-names
property is omitted.
Those clocks are required for new platforms. Enforcing the new
binding breaks existing platforms since they specify clocks (and
resets) in their glue layer node, but nothing in the core node.
I listed such exceptional cases in the DT binding. The driver
code has been relaxed to accept no clock. This change is based
on the discussion [1].
I inserted reset_control_deassert() and clk_bulk_enable() before the
first register access, i.e. dwc3_cache_hwparams().
[1] https://patchwork.kernel.org/patch/10284265/
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
2018-05-16 10:41:07 +08:00
|
|
|
- clock-names: should contain "ref", "bus_early", "suspend"
|
|
|
|
- clocks: list of phandle and clock specifier pairs corresponding to
|
|
|
|
entries in the clock-names property.
|
|
|
|
|
|
|
|
Exception for clocks:
|
|
|
|
clocks are optional if the parent node (i.e. glue-layer) is compatible to
|
|
|
|
one of the following:
|
|
|
|
"amlogic,meson-axg-dwc3"
|
|
|
|
"amlogic,meson-gxl-dwc3"
|
|
|
|
"cavium,octeon-7130-usb-uctl"
|
|
|
|
"qcom,dwc3"
|
|
|
|
"samsung,exynos5250-dwusb3"
|
2018-09-18 16:16:52 +08:00
|
|
|
"samsung,exynos5433-dwusb3"
|
usb: dwc3: support clocks and resets for DWC3 core
Historically, the clocks and resets are handled on the glue layer
side instead of the DWC3 core. For simple cases, dwc3-of-simple.c
takes care of arbitrary number of clocks and resets. The DT node
structure typically looks like as follows:
dwc3-glue {
compatible = "foo,dwc3";
clocks = ...;
resets = ...;
...
dwc3 {
compatible = "snps,dwc3";
...
};
}
By supporting the clocks and the reset in the dwc3/core.c, it will
be turned into a single node:
dwc3 {
compatible = "foo,dwc3", "snps,dwc3";
clocks = ...;
resets = ...;
...
}
This commit adds the binding of clocks and resets specific to this IP.
The number of clocks should generally be the same across SoCs, it is
just some SoCs either tie clocks together or do not provide software
control of some of the clocks.
I took the clock names from the Synopsys datasheet: "ref" (ref_clk),
"bus_early" (bus_clk_early), and "suspend" (suspend_clk).
I found only one reset line in the datasheet, hence the reset-names
property is omitted.
Those clocks are required for new platforms. Enforcing the new
binding breaks existing platforms since they specify clocks (and
resets) in their glue layer node, but nothing in the core node.
I listed such exceptional cases in the DT binding. The driver
code has been relaxed to accept no clock. This change is based
on the discussion [1].
I inserted reset_control_deassert() and clk_bulk_enable() before the
first register access, i.e. dwc3_cache_hwparams().
[1] https://patchwork.kernel.org/patch/10284265/
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
2018-05-16 10:41:07 +08:00
|
|
|
"samsung,exynos7-dwusb3"
|
|
|
|
"sprd,sc9860-dwc3"
|
|
|
|
"st,stih407-dwc3"
|
|
|
|
"ti,am437x-dwc3"
|
|
|
|
"ti,dwc3"
|
|
|
|
"ti,keystone-dwc3"
|
|
|
|
"rockchip,rk3399-dwc3"
|
|
|
|
"xlnx,zynqmp-dwc3"
|
2014-03-03 19:38:11 +08:00
|
|
|
|
|
|
|
Optional properties:
|
2013-08-09 23:40:32 +08:00
|
|
|
- usb-phy : array of phandle for the PHY device. The first element
|
|
|
|
in the array is expected to be a handle to the USB2/HS PHY and
|
|
|
|
the second element is expected to be a handle to the USB3/SS PHY
|
2014-03-03 19:38:11 +08:00
|
|
|
- phys: from the *Generic PHY* bindings
|
2016-08-19 05:37:16 +08:00
|
|
|
- phy-names: from the *Generic PHY* bindings; supported names are "usb2-phy"
|
|
|
|
or "usb3-phy".
|
usb: dwc3: support clocks and resets for DWC3 core
Historically, the clocks and resets are handled on the glue layer
side instead of the DWC3 core. For simple cases, dwc3-of-simple.c
takes care of arbitrary number of clocks and resets. The DT node
structure typically looks like as follows:
dwc3-glue {
compatible = "foo,dwc3";
clocks = ...;
resets = ...;
...
dwc3 {
compatible = "snps,dwc3";
...
};
}
By supporting the clocks and the reset in the dwc3/core.c, it will
be turned into a single node:
dwc3 {
compatible = "foo,dwc3", "snps,dwc3";
clocks = ...;
resets = ...;
...
}
This commit adds the binding of clocks and resets specific to this IP.
The number of clocks should generally be the same across SoCs, it is
just some SoCs either tie clocks together or do not provide software
control of some of the clocks.
I took the clock names from the Synopsys datasheet: "ref" (ref_clk),
"bus_early" (bus_clk_early), and "suspend" (suspend_clk).
I found only one reset line in the datasheet, hence the reset-names
property is omitted.
Those clocks are required for new platforms. Enforcing the new
binding breaks existing platforms since they specify clocks (and
resets) in their glue layer node, but nothing in the core node.
I listed such exceptional cases in the DT binding. The driver
code has been relaxed to accept no clock. This change is based
on the discussion [1].
I inserted reset_control_deassert() and clk_bulk_enable() before the
first register access, i.e. dwc3_cache_hwparams().
[1] https://patchwork.kernel.org/patch/10284265/
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
2018-05-16 10:41:07 +08:00
|
|
|
- resets: a single pair of phandle and reset specifier
|
2018-11-08 10:10:36 +08:00
|
|
|
- snps,usb2-lpm-disable: indicate if we don't want to enable USB2 HW LPM
|
2015-03-09 22:06:12 +08:00
|
|
|
- snps,usb3_lpm_capable: determines if platform is USB3 LPM capable
|
2018-11-15 14:56:48 +08:00
|
|
|
- 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.
|
2014-10-28 19:54:25 +08:00
|
|
|
- snps,disable_scramble_quirk: true when SW should disable data scrambling.
|
|
|
|
Only really useful for FPGA builds.
|
2014-10-28 19:54:26 +08:00
|
|
|
- snps,has-lpm-erratum: true when DWC3 was configured with LPM Erratum enabled
|
|
|
|
- snps,lpm-nyet-threshold: LPM NYET threshold
|
2014-10-28 19:54:27 +08:00
|
|
|
- snps,u2exit_lfps_quirk: set if we want to enable u2exit lfps quirk
|
2014-10-28 19:54:28 +08:00
|
|
|
- snps,u2ss_inp3_quirk: set if we enable P3 OK for U2/SS Inactive quirk
|
2014-10-28 19:54:29 +08:00
|
|
|
- snps,req_p1p2p3_quirk: when set, the core will always request for
|
|
|
|
P1/P2/P3 transition sequence.
|
2014-10-28 19:54:30 +08:00
|
|
|
- snps,del_p1p2p3_quirk: when set core will delay P1/P2/P3 until a certain
|
|
|
|
amount of 8B10B errors occur.
|
2014-10-28 19:54:31 +08:00
|
|
|
- snps,del_phy_power_chg_quirk: when set core will delay PHY power change
|
|
|
|
from P0 to P1/P2/P3.
|
2014-10-28 19:54:32 +08:00
|
|
|
- snps,lfps_filter_quirk: when set core will filter LFPS reception.
|
2014-10-28 19:54:33 +08:00
|
|
|
- snps,rx_detect_poll_quirk: when set core will disable a 400us delay to start
|
|
|
|
Polling LFPS after RX.Detect.
|
2014-10-31 11:11:12 +08:00
|
|
|
- snps,tx_de_emphasis_quirk: when set core will set Tx de-emphasis value.
|
|
|
|
- snps,tx_de_emphasis: the value driven to the PHY is controlled by the
|
|
|
|
LTSSM during USB3 Compliance mode.
|
2014-10-31 11:11:13 +08:00
|
|
|
- snps,dis_u3_susphy_quirk: when set core will disable USB3 suspend phy.
|
2014-10-31 11:11:14 +08:00
|
|
|
- snps,dis_u2_susphy_quirk: when set core will disable USB2 suspend phy.
|
2015-10-03 11:30:57 +08:00
|
|
|
- snps,dis_enblslpm_quirk: when set clears the enblslpm in GUSB2PHYCFG,
|
|
|
|
disabling the suspend signal to the PHY.
|
2016-03-14 17:10:51 +08:00
|
|
|
- snps,dis_rxdet_inp3_quirk: when set core will disable receiver detection
|
|
|
|
in PHY P3 power state.
|
2016-08-16 22:44:37 +08:00
|
|
|
- snps,dis-u2-freeclk-exists-quirk: when set, clear the u2_freeclk_exists
|
|
|
|
in GUSB2PHYCFG, specify that USB2 PHY doesn't provide
|
|
|
|
a free-running PHY clock.
|
2016-08-16 22:44:39 +08:00
|
|
|
- snps,dis-del-phy-power-chg-quirk: when set core will change PHY power
|
|
|
|
from P0 to P1/P2/P3 without delay.
|
2017-04-19 20:11:38 +08:00
|
|
|
- snps,dis-tx-ipgap-linecheck-quirk: when set, disable u2mac linestate check
|
|
|
|
during HS transmit.
|
2017-10-31 21:11:55 +08:00
|
|
|
- snps,dis_metastability_quirk: when set, disable metastability workaround.
|
|
|
|
CAUTION: use only if you are absolutely sure of it.
|
2014-10-31 11:11:18 +08:00
|
|
|
- snps,is-utmi-l1-suspend: true when DWC3 asserts output signal
|
|
|
|
utmi_l1_suspend_n, false when asserts utmi_sleep_n
|
|
|
|
- snps,hird-threshold: HIRD threshold
|
2015-05-13 20:26:49 +08:00
|
|
|
- snps,hsphy_interface: High-Speed PHY interface selection between "utmi" for
|
|
|
|
UTMI+ and "ulpi" for ULPI when the DWC_USB3_HSPHY_INTERFACE has value 3.
|
2015-09-04 12:44:54 +08:00
|
|
|
- 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.
|
2018-03-17 06:35:38 +08:00
|
|
|
- snps,rx-thr-num-pkt-prd: periodic ESS RX packet threshold count - host mode
|
|
|
|
only. Set this and rx-max-burst-prd to a valid,
|
|
|
|
non-zero value 1-16 (DWC_usb31 programming guide
|
|
|
|
section 1.2.4) to enable periodic ESS RX threshold.
|
|
|
|
- snps,rx-max-burst-prd: max periodic ESS RX burst size - host mode only. Set
|
|
|
|
this and rx-thr-num-pkt-prd to a valid, non-zero value
|
|
|
|
1-16 (DWC_usb31 programming guide section 1.2.4) to
|
|
|
|
enable periodic ESS RX threshold.
|
|
|
|
- snps,tx-thr-num-pkt-prd: periodic ESS TX packet threshold count - host mode
|
|
|
|
only. Set this and tx-max-burst-prd to a valid,
|
|
|
|
non-zero value 1-16 (DWC_usb31 programming guide
|
|
|
|
section 1.2.3) to enable periodic ESS TX threshold.
|
|
|
|
- snps,tx-max-burst-prd: max periodic ESS TX burst size - host mode only. Set
|
|
|
|
this and tx-thr-num-pkt-prd to a valid, non-zero value
|
|
|
|
1-16 (DWC_usb31 programming guide section 1.2.3) to
|
|
|
|
enable periodic ESS TX threshold.
|
2013-01-25 19:06:53 +08:00
|
|
|
|
2016-02-04 20:18:01 +08:00
|
|
|
- <DEPRECATED> tx-fifo-resize: determines if the FIFO *has* to be reallocated.
|
2018-07-23 18:32:38 +08:00
|
|
|
- snps,incr-burst-type-adjustment: Value for INCR burst type of GSBUSCFG0
|
|
|
|
register, undefined length INCR burst type enable and INCRx type.
|
|
|
|
When just one value, which means INCRX burst mode enabled. When
|
|
|
|
more than one value, which means undefined length INCR burst type
|
|
|
|
enabled. The values can be 1, 4, 8, 16, 32, 64, 128 and 256.
|
2016-02-04 20:18:01 +08:00
|
|
|
|
2017-01-11 22:59:42 +08:00
|
|
|
- in addition all properties from usb-xhci.txt from the current directory are
|
|
|
|
supported as well
|
|
|
|
|
|
|
|
|
2013-01-25 19:06:53 +08:00
|
|
|
This is usually a subnode to DWC3 glue to which it is connected.
|
|
|
|
|
|
|
|
dwc3@4a030000 {
|
2013-07-03 02:20:24 +08:00
|
|
|
compatible = "snps,dwc3";
|
2013-01-25 19:06:53 +08:00
|
|
|
reg = <0x4a030000 0xcfff>;
|
|
|
|
interrupts = <0 92 4>
|
|
|
|
usb-phy = <&usb2_phy>, <&usb3,phy>;
|
2018-07-23 18:32:38 +08:00
|
|
|
snps,incr-burst-type-adjustment = <1>, <4>, <8>, <16>;
|
2013-01-25 19:06:53 +08:00
|
|
|
};
|