Hi,
At some point the USB 3 port broke on Rock64 boards; users report it working back on 4.4 kernels, but by 5.3 it wasn't any more (eg, https://forum.armbian.com/topic/12439-rock64-usb-3-broken/).
These two patches add a USB3 node to the device-tree, which allows it to work again. I've tested a gigabit nic and was able to get close to 1000mbit speeds over the USB 3 ports. I'd love to see these two unintrusive patches added to 5.10.
Thanks, Andres
Cameron Nemo (2): arm64: dts: rockchip: add rk3328 dwc3 usb controller node arm64: dts: rockchip: Enable USB3 for rk3328 Rock64
arch/arm64/boot/dts/rockchip/rk3328-rock64.dts | 5 +++++ arch/arm64/boot/dts/rockchip/rk3328.dtsi | 19 +++++++++++++++++++ 2 files changed, 24 insertions(+)
From: Cameron Nemo cnemo@tutanota.com
commit 44dd5e2106dc2fd01697b539085818d1d1c58df0 upstream
RK3328 SoCs have one USB 3.0 OTG controller which uses DWC_USB3 core's general architecture. It can act as static xHCI host controller, static device controller, USB 3.0/2.0 OTG basing on ID of USB3.0 PHY.
Signed-off-by: William Wu william.wu@rock-chips.com Signed-off-by: Cameron Nemo cnemo@tutanota.com Signed-off-by: Johan Jonker jbx6244@gmail.com Signed-off-by: Heiko Stuebner heiko@sntech.de Link: https://lore.kernel.org/r/20210209192350.7130-7-jbx6244@gmail.com Signed-off-by: Heiko Stuebner heiko@sntech.de --- arch/arm64/boot/dts/rockchip/rk3328.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)
diff --git a/arch/arm64/boot/dts/rockchip/rk3328.dtsi b/arch/arm64/boot/dts/rockchip/rk3328.dtsi index 93c734d8a46c..de1e5e8a0e88 100644 --- a/arch/arm64/boot/dts/rockchip/rk3328.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3328.dtsi @@ -984,6 +984,25 @@ usb_host0_ohci: usb@ff5d0000 { status = "disabled"; };
+ usbdrd3: usb@ff600000 { + compatible = "rockchip,rk3328-dwc3", "snps,dwc3"; + reg = <0x0 0xff600000 0x0 0x100000>; + interrupts = <GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&cru SCLK_USB3OTG_REF>, <&cru SCLK_USB3OTG_SUSPEND>, + <&cru ACLK_USB3OTG>; + clock-names = "ref_clk", "suspend_clk", + "bus_clk"; + dr_mode = "otg"; + phy_type = "utmi_wide"; + snps,dis-del-phy-power-chg-quirk; + snps,dis_enblslpm_quirk; + snps,dis-tx-ipgap-linecheck-quirk; + snps,dis-u2-freeclk-exists-quirk; + snps,dis_u2_susphy_quirk; + snps,dis_u3_susphy_quirk; + status = "disabled"; + }; + gic: interrupt-controller@ff811000 { compatible = "arm,gic-400"; #interrupt-cells = <3>;
From: Cameron Nemo cnemo@tutanota.com
commit bbac8bd65f5402281cb7b0452c1c5f367387b459 upstream
Enable USB3 nodes for the rk3328-based PINE Rock64 board.
The separate power regulator is not added as it is controlled by the same GPIO line as the existing VBUS regulators, so it is already enabled. Also there is no port representation to tie the regulator to.
[wens@csie.org: Rebased onto v5.12]
Signed-off-by: Cameron Nemo cnemo@tutanota.com [wens@csie.org: Rewrote commit message] Signed-off-by: Chen-Yu Tsai wens@csie.org Link: https://lore.kernel.org/r/20210504083616.9654-2-wens@kernel.org Signed-off-by: Heiko Stuebner heiko@sntech.de --- arch/arm64/boot/dts/rockchip/rk3328-rock64.dts | 5 +++++ 1 file changed, 5 insertions(+)
diff --git a/arch/arm64/boot/dts/rockchip/rk3328-rock64.dts b/arch/arm64/boot/dts/rockchip/rk3328-rock64.dts index 86cfb5c50a94..95ab6928cfd4 100644 --- a/arch/arm64/boot/dts/rockchip/rk3328-rock64.dts +++ b/arch/arm64/boot/dts/rockchip/rk3328-rock64.dts @@ -384,6 +384,11 @@ &usb20_otg { status = "okay"; };
+&usbdrd3 { + dr_mode = "host"; + status = "okay"; +}; + &usb_host0_ehci { status = "okay"; };
On Mon, Jul 12, 2021 at 07:42:51PM -0400, Andres Salomon wrote:
Hi,
At some point the USB 3 port broke on Rock64 boards; users report it working back on 4.4 kernels, but by 5.3 it wasn't any more (eg, https://forum.armbian.com/topic/12439-rock64-usb-3-broken/).
These two patches add a USB3 node to the device-tree, which allows it to work again. I've tested a gigabit nic and was able to get close to 1000mbit speeds over the USB 3 ports. I'd love to see these two unintrusive patches added to 5.10.
Now queued up, thanks
greg k-h
linux-stable-mirror@lists.linaro.org