aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/bcm53xx/patches-5.10/033-v5.15-0005-ARM-dts-NSP-Move-USB3-PHY-to-internal-MDIO-bus.patch
diff options
context:
space:
mode:
authorRafał Miłecki <rafal@milecki.pl>2021-08-29 22:53:55 +0200
committerRafał Miłecki <rafal@milecki.pl>2021-08-29 22:57:13 +0200
commitbce00f47e5d67e5a33e9d7fa137cbe0a5d3d334b (patch)
tree818e03abdd346f7ae84e8e0f77bf2631ec6bef0d /target/linux/bcm53xx/patches-5.10/033-v5.15-0005-ARM-dts-NSP-Move-USB3-PHY-to-internal-MDIO-bus.patch
parent505b7a2d08a79780f50a2adb383f57ef63bd85ac (diff)
downloadupstream-bce00f47e5d67e5a33e9d7fa137cbe0a5d3d334b.tar.gz
upstream-bce00f47e5d67e5a33e9d7fa137cbe0a5d3d334b.tar.bz2
upstream-bce00f47e5d67e5a33e9d7fa137cbe0a5d3d334b.zip
bcm53xx: backport the latest upstream DT changes
This includes: 1. BCM5301X changes from 5.14 and queued 5.15 stuff 2. NSP changes from 5.11 - 5.15 for kernel 5.10 Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Diffstat (limited to 'target/linux/bcm53xx/patches-5.10/033-v5.15-0005-ARM-dts-NSP-Move-USB3-PHY-to-internal-MDIO-bus.patch')
-rw-r--r--target/linux/bcm53xx/patches-5.10/033-v5.15-0005-ARM-dts-NSP-Move-USB3-PHY-to-internal-MDIO-bus.patch85
1 files changed, 85 insertions, 0 deletions
diff --git a/target/linux/bcm53xx/patches-5.10/033-v5.15-0005-ARM-dts-NSP-Move-USB3-PHY-to-internal-MDIO-bus.patch b/target/linux/bcm53xx/patches-5.10/033-v5.15-0005-ARM-dts-NSP-Move-USB3-PHY-to-internal-MDIO-bus.patch
new file mode 100644
index 0000000000..b760e0fcf2
--- /dev/null
+++ b/target/linux/bcm53xx/patches-5.10/033-v5.15-0005-ARM-dts-NSP-Move-USB3-PHY-to-internal-MDIO-bus.patch
@@ -0,0 +1,85 @@
+From 1c615401bddb1be21e1d375aaa071680f40f1ae2 Mon Sep 17 00:00:00 2001
+From: Matthew Hagan <mnhagan88@gmail.com>
+Date: Sun, 13 Jun 2021 10:46:37 +0100
+Subject: [PATCH] ARM: dts: NSP: Move USB3 PHY to internal MDIO bus
+
+This patch largely replicates Vivek Unune's patch "ARM: dts:
+BCM5301X:Make usb3 phy use mdio phy driver"[1] for the NSP platform,
+whereby we need to create an mdio-mux to facilitate switches
+configured via external MDIO, in this case on the Meraki MX65.
+
+However in doing so, we are creating an overlap with usb3_phy's
+ccb-mii range. To resolve this, usb3_phy should be moved to a child
+node of the internal MDIO bus. The result is heavily based upon Vivek's
+patch. This has also been cross-referenced with Yendapally Reddy's
+earlier work which utilised the subsequently dropped brcm,nsp-usb3-phy
+driver: "[PATCH v2 4/4] arm: dts: nsp: Add USB nodes to device tree"
+[2]. Finally, this change provides conformance to the bcm-ns-usb3-phy
+documentation, utilising the required usb3-dmp-syscon property. Note
+that support for the deprecated ccb-mii bindings has been dropped as of
+"phy: phy-bcm-ns-usb3: drop support for deprecated DT binding"[3].
+
+[1] https://lore.kernel.org/patchwork/patch/933971/
+[2] https://www.spinics.net/lists/arm-kernel/msg555132.html
+[3] https://lore.kernel.org/linux-devicetree/20201113113423.9466-1-zajec5@gmail.com/
+
+Signed-off-by: Matthew Hagan <mnhagan88@gmail.com>
+Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
+---
+ arch/arm/boot/dts/bcm-nsp.dtsi | 38 +++++++++++++++++++++++++++-------
+ 1 file changed, 31 insertions(+), 7 deletions(-)
+
+--- a/arch/arm/boot/dts/bcm-nsp.dtsi
++++ b/arch/arm/boot/dts/bcm-nsp.dtsi
+@@ -370,6 +370,35 @@
+ #address-cells = <1>;
+ };
+
++ mdio-mux@32000 {
++ compatible = "mdio-mux-mmioreg";
++ reg = <0x32000 0x4>;
++ mux-mask = <0x200>;
++ #address-cells = <1>;
++ #size-cells = <0>;
++ mdio-parent-bus = <&mdio>;
++
++ mdio_int: mdio@0 {
++ reg = <0x0>;
++ #address-cells = <1>;
++ #size-cells = <0>;
++
++ usb3_phy: usb3-phy@10 {
++ compatible = "brcm,ns-bx-usb3-phy";
++ reg = <0x10>;
++ usb3-dmp-syscon = <&usb3_dmp>;
++ #phy-cells = <0>;
++ status = "disabled";
++ };
++ };
++
++ mdio_ext: mdio@200 {
++ reg = <0x200>;
++ #address-cells = <1>;
++ #size-cells = <0>;
++ };
++ };
++
+ rng: rng@33000 {
+ compatible = "brcm,bcm-nsp-rng";
+ reg = <0x33000 0x14>;
+@@ -528,13 +557,8 @@
+ };
+ };
+
+- usb3_phy: usb3-phy@104000 {
+- compatible = "brcm,ns-bx-usb3-phy";
+- reg = <0x104000 0x1000>,
+- <0x032000 0x1000>;
+- reg-names = "dmp", "ccb-mii";
+- #phy-cells = <0>;
+- status = "disabled";
++ usb3_dmp: syscon@104000 {
++ reg = <0x104000 0x1000>;
+ };
+ };
+