* [PATCH v2 0/4] usb: dwc2: Another attempt handling rk3288's remote wake quirk
@ 2019-04-16 21:53 Douglas Anderson
2019-04-16 21:53 ` [PATCH v2 3/4] ARM: dts: rockchip: Hook resets up to USB PHYs on rk3288 Douglas Anderson
2019-04-16 21:53 ` [PATCH v2 4/4] ARM: dts: rockchip: Add quirk for resetting rk3288's dwc2 host on wakeup Douglas Anderson
0 siblings, 2 replies; 3+ messages in thread
From: Douglas Anderson @ 2019-04-16 21:53 UTC (permalink / raw)
To: Rob Herring, Minas Harutyunyan, Heiko Stuebner, Felipe Balbi
Cc: Mark Rutland, devicetree, linux-usb, amstan, Greg Kroah-Hartman,
Randy Li, Douglas Anderson, linux-kernel, linux-rockchip, mka,
ryandcase, Elaine Zhang, jwerner, linux-arm-kernel
This is another attempt to upstream the code to unwedge the rk3288's
"host" USB port when it sees a remote wakeup. Previously I attempted
this [1] and it appears that Randy Li made some attempts too [2] which
resulted in at least the PHY bindings for the USB PHY landing as well
as the USB PHY support. Nice!
Hopefully this addresses previous comments and could land this time?
[1] https://lkml.kernel.org/r/1446236275-12698-2-git-send-email-dianders@chromium.org
[2] https://lkml.kernel.org/r/1472939729-15187-4-git-send-email-ayaka@soulik.info
Changes in v2:
- Cancel the work when dwc2 is freed (Matthias).
Douglas Anderson (4):
dt-bindings: usb: dwc2: Document quirk to reset PHY upon wakeup
usb: dwc2: optionally assert phy reset when waking up
ARM: dts: rockchip: Hook resets up to USB PHYs on rk3288.
ARM: dts: rockchip: Add quirk for resetting rk3288's dwc2 host on
wakeup
Documentation/devicetree/bindings/usb/dwc2.txt | 2 ++
arch/arm/boot/dts/rk3288.dtsi | 7 +++++++
drivers/usb/dwc2/core.h | 5 +++++
drivers/usb/dwc2/core_intr.c | 12 ++++++++++++
drivers/usb/dwc2/hcd.c | 18 +++++++++++++++---
drivers/usb/dwc2/platform.c | 9 +++++++++
6 files changed, 50 insertions(+), 3 deletions(-)
--
2.21.0.593.g511ec345e18-goog
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH v2 3/4] ARM: dts: rockchip: Hook resets up to USB PHYs on rk3288.
2019-04-16 21:53 [PATCH v2 0/4] usb: dwc2: Another attempt handling rk3288's remote wake quirk Douglas Anderson
@ 2019-04-16 21:53 ` Douglas Anderson
2019-04-16 21:53 ` [PATCH v2 4/4] ARM: dts: rockchip: Add quirk for resetting rk3288's dwc2 host on wakeup Douglas Anderson
1 sibling, 0 replies; 3+ messages in thread
From: Douglas Anderson @ 2019-04-16 21:53 UTC (permalink / raw)
To: Rob Herring, Minas Harutyunyan, Heiko Stuebner, Felipe Balbi
Cc: Mark Rutland, devicetree, linux-usb, amstan, Randy Li,
Douglas Anderson, linux-kernel, linux-rockchip, mka, ryandcase,
Elaine Zhang, jwerner, linux-arm-kernel
Let's hook up the resets to the three USB PHYs on rk3288 as per the
bindings. This is in preparation for a future patch that will set the
"snps,reset-phy-on-wake" on the host port.
Signed-off-by: Douglas Anderson <dianders@chromium.org>
---
Changes in v2: None
arch/arm/boot/dts/rk3288.dtsi | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/arch/arm/boot/dts/rk3288.dtsi b/arch/arm/boot/dts/rk3288.dtsi
index 74c9517c4f92..7e70ecf2b95a 100644
--- a/arch/arm/boot/dts/rk3288.dtsi
+++ b/arch/arm/boot/dts/rk3288.dtsi
@@ -909,6 +909,8 @@
clocks = <&cru SCLK_OTGPHY0>;
clock-names = "phyclk";
#clock-cells = <0>;
+ resets = <&cru SRST_USBOTG_PHY>;
+ reset-names = "phy-reset";
};
usbphy1: usb-phy@334 {
@@ -917,6 +919,8 @@
clocks = <&cru SCLK_OTGPHY1>;
clock-names = "phyclk";
#clock-cells = <0>;
+ resets = <&cru SRST_USBHOST0_PHY>;
+ reset-names = "phy-reset";
};
usbphy2: usb-phy@348 {
@@ -925,6 +929,8 @@
clocks = <&cru SCLK_OTGPHY2>;
clock-names = "phyclk";
#clock-cells = <0>;
+ resets = <&cru SRST_USBHOST1_PHY>;
+ reset-names = "phy-reset";
};
};
};
--
2.21.0.593.g511ec345e18-goog
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH v2 4/4] ARM: dts: rockchip: Add quirk for resetting rk3288's dwc2 host on wakeup
2019-04-16 21:53 [PATCH v2 0/4] usb: dwc2: Another attempt handling rk3288's remote wake quirk Douglas Anderson
2019-04-16 21:53 ` [PATCH v2 3/4] ARM: dts: rockchip: Hook resets up to USB PHYs on rk3288 Douglas Anderson
@ 2019-04-16 21:53 ` Douglas Anderson
1 sibling, 0 replies; 3+ messages in thread
From: Douglas Anderson @ 2019-04-16 21:53 UTC (permalink / raw)
To: Rob Herring, Minas Harutyunyan, Heiko Stuebner, Felipe Balbi
Cc: Mark Rutland, devicetree, linux-usb, amstan, Randy Li,
Douglas Anderson, linux-kernel, linux-rockchip, mka, ryandcase,
Elaine Zhang, jwerner, linux-arm-kernel
The "host" USB port on rk3288 has a hardware errata where we've got to
assert a PHY reset whenever we see a remote wakeup. Add that quirk
property to the device tree.
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Matthias Kaehlcke <mka@chromium.org>
---
Changes in v2: None
arch/arm/boot/dts/rk3288.dtsi | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/arm/boot/dts/rk3288.dtsi b/arch/arm/boot/dts/rk3288.dtsi
index 7e70ecf2b95a..aa017abf4f42 100644
--- a/arch/arm/boot/dts/rk3288.dtsi
+++ b/arch/arm/boot/dts/rk3288.dtsi
@@ -621,6 +621,7 @@
dr_mode = "host";
phys = <&usbphy2>;
phy-names = "usb2-phy";
+ snps,reset-phy-on-wake;
status = "disabled";
};
--
2.21.0.593.g511ec345e18-goog
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-04-16 21:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-16 21:53 [PATCH v2 0/4] usb: dwc2: Another attempt handling rk3288's remote wake quirk Douglas Anderson
2019-04-16 21:53 ` [PATCH v2 3/4] ARM: dts: rockchip: Hook resets up to USB PHYs on rk3288 Douglas Anderson
2019-04-16 21:53 ` [PATCH v2 4/4] ARM: dts: rockchip: Add quirk for resetting rk3288's dwc2 host on wakeup Douglas Anderson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).