linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings
@ 2022-09-12 17:50 Vladimir Oltean
  2022-09-12 17:50 ` [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks Vladimir Oltean
                   ` (3 more replies)
  0 siblings, 4 replies; 20+ messages in thread
From: Vladimir Oltean @ 2022-09-12 17:50 UTC (permalink / raw)
  To: netdev
  Cc: Andrew Lunn, Vivien Didelot, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Rob Herring, Krzysztof Kozlowski, George McCollister,
	Kurt Kanzenbach, Matthias Brugger, Woojung Huh, UNGLinuxDriver,
	Linus Walleij, Alvin Šipraga, Clément Léger,
	Arınç ÜNAL, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

As explained in more detail in patch 1/3, label = "cpu" is not part of
DSA's device tree bindings, yet we have some checks in the dt-schema for
mt7530 which are written as if it was.

Reformulate those checks, and remove all occurrences of this seemingly
used, but actually unused, property from the binding examples.

Vladimir Oltean (3):
  dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper
    checks
  dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports
  dt-bindings: net: dsa: remove label = "cpu" from examples

 .../devicetree/bindings/net/dsa/ar9331.txt    |  1 -
 .../bindings/net/dsa/arrow,xrs700x.yaml       |  1 -
 .../devicetree/bindings/net/dsa/brcm,b53.yaml |  2 --
 .../net/dsa/hirschmann,hellcreek.yaml         |  1 -
 .../devicetree/bindings/net/dsa/lan9303.txt   |  2 --
 .../bindings/net/dsa/lantiq-gswip.txt         |  1 -
 .../bindings/net/dsa/mediatek,mt7530.yaml     | 22 +++----------------
 .../bindings/net/dsa/microchip,ksz.yaml       |  2 --
 .../devicetree/bindings/net/dsa/qca8k.yaml    |  3 ---
 .../devicetree/bindings/net/dsa/realtek.yaml  |  2 --
 .../bindings/net/dsa/renesas,rzn1-a5psw.yaml  |  1 -
 .../bindings/net/dsa/vitesse,vsc73xx.txt      |  2 --
 12 files changed, 3 insertions(+), 37 deletions(-)

-- 
2.34.1


_______________________________________________
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] 20+ messages in thread

* [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks
  2022-09-12 17:50 [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings Vladimir Oltean
@ 2022-09-12 17:50 ` Vladimir Oltean
  2022-09-12 17:59   ` Florian Fainelli
                     ` (3 more replies)
  2022-09-12 17:50 ` [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports Vladimir Oltean
                   ` (2 subsequent siblings)
  3 siblings, 4 replies; 20+ messages in thread
From: Vladimir Oltean @ 2022-09-12 17:50 UTC (permalink / raw)
  To: netdev
  Cc: Andrew Lunn, Vivien Didelot, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Rob Herring, Krzysztof Kozlowski, George McCollister,
	Kurt Kanzenbach, Matthias Brugger, Woojung Huh, UNGLinuxDriver,
	Linus Walleij, Alvin Šipraga, Clément Léger,
	Arınç ÜNAL, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

The fact that some DSA device trees use 'label = "cpu"' for the CPU port
is nothing but blind cargo cult copying. The 'label' property was never
part of the DSA DT bindings for anything except the user ports, where it
provided a hint as to what name the created netdevs should use.

DSA does use the "cpu" port label to identify a CPU port in dsa_port_parse(),
but this is only for non-OF code paths (platform data).

The proper way to identify a CPU port is to look at whether the
'ethernet' phandle is present.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
---
 .../devicetree/bindings/net/dsa/mediatek,mt7530.yaml | 12 +++---------
 1 file changed, 3 insertions(+), 9 deletions(-)

diff --git a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
index f9e7b6e20b35..fa271ee16b5e 100644
--- a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
@@ -163,9 +163,7 @@ patternProperties:
         allOf:
           - $ref: dsa-port.yaml#
           - if:
-              properties:
-                label:
-                  const: cpu
+              required: [ ethernet ]
             then:
               required:
                 - phy-mode
@@ -187,9 +185,7 @@ $defs:
         patternProperties:
           "^(ethernet-)?port@[0-9]+$":
             if:
-              properties:
-                label:
-                  const: cpu
+              required: [ ethernet ]
             then:
               if:
                 properties:
@@ -215,9 +211,7 @@ $defs:
         patternProperties:
           "^(ethernet-)?port@[0-9]+$":
             if:
-              properties:
-                label:
-                  const: cpu
+              required: [ ethernet ]
             then:
               if:
                 properties:
-- 
2.34.1


_______________________________________________
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] 20+ messages in thread

* [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports
  2022-09-12 17:50 [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings Vladimir Oltean
  2022-09-12 17:50 ` [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks Vladimir Oltean
@ 2022-09-12 17:50 ` Vladimir Oltean
  2022-09-12 18:07   ` Florian Fainelli
                     ` (2 more replies)
  2022-09-12 17:50 ` [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples Vladimir Oltean
  2022-09-20  1:10 ` [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings patchwork-bot+netdevbpf
  3 siblings, 3 replies; 20+ messages in thread
From: Vladimir Oltean @ 2022-09-12 17:50 UTC (permalink / raw)
  To: netdev
  Cc: Andrew Lunn, Vivien Didelot, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Rob Herring, Krzysztof Kozlowski, George McCollister,
	Kurt Kanzenbach, Matthias Brugger, Woojung Huh, UNGLinuxDriver,
	Linus Walleij, Alvin Šipraga, Clément Léger,
	Arınç ÜNAL, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

The common dsa-port.yaml does this (and more) since commit 2ec2fb8331af
("dt-bindings: net: dsa: make phylink bindings required for CPU/DSA
ports").

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
---
 Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
index fa271ee16b5e..84bb36cab518 100644
--- a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
@@ -165,9 +165,6 @@ patternProperties:
           - if:
               required: [ ethernet ]
             then:
-              required:
-                - phy-mode
-
               properties:
                 reg:
                   enum:
-- 
2.34.1


_______________________________________________
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] 20+ messages in thread

* [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
  2022-09-12 17:50 [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings Vladimir Oltean
  2022-09-12 17:50 ` [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks Vladimir Oltean
  2022-09-12 17:50 ` [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports Vladimir Oltean
@ 2022-09-12 17:50 ` Vladimir Oltean
  2022-09-12 18:12   ` Florian Fainelli
                     ` (2 more replies)
  2022-09-20  1:10 ` [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings patchwork-bot+netdevbpf
  3 siblings, 3 replies; 20+ messages in thread
From: Vladimir Oltean @ 2022-09-12 17:50 UTC (permalink / raw)
  To: netdev
  Cc: Andrew Lunn, Vivien Didelot, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Rob Herring, Krzysztof Kozlowski, George McCollister,
	Kurt Kanzenbach, Matthias Brugger, Woojung Huh, UNGLinuxDriver,
	Linus Walleij, Alvin Šipraga, Clément Léger,
	Arınç ÜNAL, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

This is not used by the DSA dt-binding, so remove it from all examples.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
---
 Documentation/devicetree/bindings/net/dsa/ar9331.txt       | 1 -
 .../devicetree/bindings/net/dsa/arrow,xrs700x.yaml         | 1 -
 Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml    | 2 --
 .../devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml  | 1 -
 Documentation/devicetree/bindings/net/dsa/lan9303.txt      | 2 --
 Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt | 1 -
 .../devicetree/bindings/net/dsa/mediatek,mt7530.yaml       | 7 -------
 .../devicetree/bindings/net/dsa/microchip,ksz.yaml         | 2 --
 Documentation/devicetree/bindings/net/dsa/qca8k.yaml       | 3 ---
 Documentation/devicetree/bindings/net/dsa/realtek.yaml     | 2 --
 .../devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml    | 1 -
 .../devicetree/bindings/net/dsa/vitesse,vsc73xx.txt        | 2 --
 12 files changed, 25 deletions(-)

diff --git a/Documentation/devicetree/bindings/net/dsa/ar9331.txt b/Documentation/devicetree/bindings/net/dsa/ar9331.txt
index 320607cbbb17..f824fdae0da2 100644
--- a/Documentation/devicetree/bindings/net/dsa/ar9331.txt
+++ b/Documentation/devicetree/bindings/net/dsa/ar9331.txt
@@ -76,7 +76,6 @@ eth1: ethernet@1a000000 {
 
 				switch_port0: port@0 {
 					reg = <0x0>;
-					label = "cpu";
 					ethernet = <&eth1>;
 
 					phy-mode = "gmii";
diff --git a/Documentation/devicetree/bindings/net/dsa/arrow,xrs700x.yaml b/Documentation/devicetree/bindings/net/dsa/arrow,xrs700x.yaml
index eb01a8f37ce4..259a0c6547f3 100644
--- a/Documentation/devicetree/bindings/net/dsa/arrow,xrs700x.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/arrow,xrs700x.yaml
@@ -61,7 +61,6 @@ examples:
                 };
                 ethernet-port@3 {
                     reg = <3>;
-                    label = "cpu";
                     ethernet = <&fec1>;
                     phy-mode = "rgmii-id";
 
diff --git a/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml b/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
index 2e01371b8288..1219b830b1a4 100644
--- a/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
@@ -169,7 +169,6 @@ examples:
 
                 port@8 {
                     reg = <8>;
-                    label = "cpu";
                     phy-mode = "rgmii-txid";
                     ethernet = <&eth0>;
                     fixed-link {
@@ -252,7 +251,6 @@ examples:
 
                 port@8 {
                     ethernet = <&amac2>;
-                    label = "cpu";
                     reg = <8>;
                     phy-mode = "internal";
 
diff --git a/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml b/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml
index 1ff44dd68a61..73b774eadd0b 100644
--- a/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml
@@ -91,7 +91,6 @@ examples:
 
                 port@0 {
                     reg = <0>;
-                    label = "cpu";
                     ethernet = <&gmac0>;
                     phy-mode = "mii";
 
diff --git a/Documentation/devicetree/bindings/net/dsa/lan9303.txt b/Documentation/devicetree/bindings/net/dsa/lan9303.txt
index 464d6bf87605..46a732087f5c 100644
--- a/Documentation/devicetree/bindings/net/dsa/lan9303.txt
+++ b/Documentation/devicetree/bindings/net/dsa/lan9303.txt
@@ -46,7 +46,6 @@ I2C managed mode:
 
 			port@0 { /* RMII fixed link to master */
 				reg = <0>;
-				label = "cpu";
 				ethernet = <&master>;
 			};
 
@@ -83,7 +82,6 @@ MDIO managed mode:
 
 					port@0 {
 						reg = <0>;
-						label = "cpu";
 						ethernet = <&master>;
 					};
 
diff --git a/Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt b/Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt
index e3829d3e480e..8bb1eff21cb1 100644
--- a/Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt
+++ b/Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt
@@ -96,7 +96,6 @@ switch@e108000 {
 
 		port@6 {
 			reg = <0x6>;
-			label = "cpu";
 			ethernet = <&eth0>;
 		};
 	};
diff --git a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
index 84bb36cab518..bc6446e1f55a 100644
--- a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
@@ -325,7 +325,6 @@ examples:
 
                 port@6 {
                     reg = <6>;
-                    label = "cpu";
                     ethernet = <&gmac0>;
                     phy-mode = "rgmii";
 
@@ -389,7 +388,6 @@ examples:
 
                 port@6 {
                     reg = <6>;
-                    label = "cpu";
                     ethernet = <&gmac0>;
                     phy-mode = "trgmii";
 
@@ -454,7 +452,6 @@ examples:
 
                 port@6 {
                     reg = <6>;
-                    label = "cpu";
                     ethernet = <&gmac0>;
                     phy-mode = "2500base-x";
 
@@ -521,7 +518,6 @@ examples:
 
                 port@6 {
                     reg = <6>;
-                    label = "cpu";
                     ethernet = <&gmac0>;
                     phy-mode = "trgmii";
 
@@ -610,7 +606,6 @@ examples:
 
                     port@6 {
                         reg = <6>;
-                        label = "cpu";
                         ethernet = <&gmac0>;
                         phy-mode = "trgmii";
 
@@ -699,7 +694,6 @@ examples:
 
                     port@6 {
                         reg = <6>;
-                        label = "cpu";
                         ethernet = <&gmac0>;
                         phy-mode = "trgmii";
 
@@ -787,7 +781,6 @@ examples:
 
                     port@6 {
                         reg = <6>;
-                        label = "cpu";
                         ethernet = <&gmac0>;
                         phy-mode = "trgmii";
 
diff --git a/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml b/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
index 456802affc9d..4da75b1f9533 100644
--- a/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
@@ -107,7 +107,6 @@ examples:
                 };
                 port@5 {
                     reg = <5>;
-                    label = "cpu";
                     ethernet = <&eth0>;
                     phy-mode = "rgmii";
 
@@ -146,7 +145,6 @@ examples:
                 };
                 port@6 {
                     reg = <6>;
-                    label = "cpu";
                     ethernet = <&eth0>;
                     phy-mode = "rgmii";
 
diff --git a/Documentation/devicetree/bindings/net/dsa/qca8k.yaml b/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
index f3c88371d76c..978162df51f7 100644
--- a/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
@@ -159,7 +159,6 @@ examples:
 
                 port@0 {
                     reg = <0>;
-                    label = "cpu";
                     ethernet = <&gmac1>;
                     phy-mode = "rgmii";
 
@@ -221,7 +220,6 @@ examples:
 
                 port@0 {
                     reg = <0>;
-                    label = "cpu";
                     ethernet = <&gmac1>;
                     phy-mode = "rgmii";
 
@@ -268,7 +266,6 @@ examples:
 
                 port@6 {
                     reg = <0>;
-                    label = "cpu";
                     ethernet = <&gmac1>;
                     phy-mode = "sgmii";
 
diff --git a/Documentation/devicetree/bindings/net/dsa/realtek.yaml b/Documentation/devicetree/bindings/net/dsa/realtek.yaml
index 4f99aff029dc..1a7d45a8ad66 100644
--- a/Documentation/devicetree/bindings/net/dsa/realtek.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/realtek.yaml
@@ -189,7 +189,6 @@ examples:
                             };
                             port@5 {
                                     reg = <5>;
-                                    label = "cpu";
                                     ethernet = <&gmac0>;
                                     phy-mode = "rgmii";
                                     fixed-link {
@@ -277,7 +276,6 @@ examples:
                             };
                             port@6 {
                                     reg = <6>;
-                                    label = "cpu";
                                     ethernet = <&fec1>;
                                     phy-mode = "rgmii";
                                     tx-internal-delay-ps = <2000>;
diff --git a/Documentation/devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml b/Documentation/devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml
index 14a1f0b4c32b..7ca9c19a157c 100644
--- a/Documentation/devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml
@@ -130,7 +130,6 @@ examples:
             port@4 {
                 reg = <4>;
                 ethernet = <&gmac2>;
-                label = "cpu";
                 phy-mode = "internal";
 
                 fixed-link {
diff --git a/Documentation/devicetree/bindings/net/dsa/vitesse,vsc73xx.txt b/Documentation/devicetree/bindings/net/dsa/vitesse,vsc73xx.txt
index bbf4a13f6d75..258bef483673 100644
--- a/Documentation/devicetree/bindings/net/dsa/vitesse,vsc73xx.txt
+++ b/Documentation/devicetree/bindings/net/dsa/vitesse,vsc73xx.txt
@@ -75,7 +75,6 @@ switch@0 {
 		};
 		vsc: port@6 {
 			reg = <6>;
-			label = "cpu";
 			ethernet = <&gmac1>;
 			phy-mode = "rgmii";
 			fixed-link {
@@ -117,7 +116,6 @@ switch@2,0 {
 		};
 		vsc: port@6 {
 			reg = <6>;
-			label = "cpu";
 			ethernet = <&enet0>;
 			phy-mode = "rgmii";
 			fixed-link {
-- 
2.34.1


_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks
  2022-09-12 17:50 ` [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks Vladimir Oltean
@ 2022-09-12 17:59   ` Florian Fainelli
  2022-09-13  8:19   ` Arınç ÜNAL
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 20+ messages in thread
From: Florian Fainelli @ 2022-09-12 17:59 UTC (permalink / raw)
  To: Vladimir Oltean, netdev
  Cc: Andrew Lunn, Vivien Didelot, Vladimir Oltean, David S. Miller,
	Eric Dumazet, Jakub Kicinski, Paolo Abeni, Rob Herring,
	Krzysztof Kozlowski, George McCollister, Kurt Kanzenbach,
	Matthias Brugger, Woojung Huh, UNGLinuxDriver, Linus Walleij,
	Alvin Šipraga, Clément Léger,
	Arınç ÜNAL, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

On 9/12/22 10:50, Vladimir Oltean wrote:
> The fact that some DSA device trees use 'label = "cpu"' for the CPU port
> is nothing but blind cargo cult copying. The 'label' property was never
> part of the DSA DT bindings for anything except the user ports, where it
> provided a hint as to what name the created netdevs should use.
> 
> DSA does use the "cpu" port label to identify a CPU port in dsa_port_parse(),
> but this is only for non-OF code paths (platform data).
> 
> The proper way to identify a CPU port is to look at whether the
> 'ethernet' phandle is present.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>

Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
-- 
Florian

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports
  2022-09-12 17:50 ` [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports Vladimir Oltean
@ 2022-09-12 18:07   ` Florian Fainelli
  2022-09-13  8:19   ` Arınç ÜNAL
  2022-09-13 15:51   ` Rob Herring
  2 siblings, 0 replies; 20+ messages in thread
From: Florian Fainelli @ 2022-09-12 18:07 UTC (permalink / raw)
  To: Vladimir Oltean, netdev
  Cc: Andrew Lunn, Vivien Didelot, Vladimir Oltean, David S. Miller,
	Eric Dumazet, Jakub Kicinski, Paolo Abeni, Rob Herring,
	Krzysztof Kozlowski, George McCollister, Kurt Kanzenbach,
	Matthias Brugger, Woojung Huh, UNGLinuxDriver, Linus Walleij,
	Alvin Šipraga, Clément Léger,
	Arınç ÜNAL, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

On 9/12/22 10:50, Vladimir Oltean wrote:
> The common dsa-port.yaml does this (and more) since commit 2ec2fb8331af
> ("dt-bindings: net: dsa: make phylink bindings required for CPU/DSA
> ports").
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>

Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
-- 
Florian

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
  2022-09-12 17:50 ` [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples Vladimir Oltean
@ 2022-09-12 18:12   ` Florian Fainelli
  2022-09-13  8:20   ` Arınç ÜNAL
  2022-09-13 15:54   ` Rob Herring
  2 siblings, 0 replies; 20+ messages in thread
From: Florian Fainelli @ 2022-09-12 18:12 UTC (permalink / raw)
  To: Vladimir Oltean, netdev
  Cc: Andrew Lunn, Vivien Didelot, Vladimir Oltean, David S. Miller,
	Eric Dumazet, Jakub Kicinski, Paolo Abeni, Rob Herring,
	Krzysztof Kozlowski, George McCollister, Kurt Kanzenbach,
	Matthias Brugger, Woojung Huh, UNGLinuxDriver, Linus Walleij,
	Alvin Šipraga, Clément Léger,
	Arınç ÜNAL, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

On 9/12/22 10:50, Vladimir Oltean wrote:
> This is not used by the DSA dt-binding, so remove it from all examples.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>

Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
-- 
Florian

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks
  2022-09-12 17:50 ` [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks Vladimir Oltean
  2022-09-12 17:59   ` Florian Fainelli
@ 2022-09-13  8:19   ` Arınç ÜNAL
  2022-09-13 15:51   ` Rob Herring
  2022-09-13 15:55   ` Arınç ÜNAL
  3 siblings, 0 replies; 20+ messages in thread
From: Arınç ÜNAL @ 2022-09-13  8:19 UTC (permalink / raw)
  To: Vladimir Oltean, netdev
  Cc: Andrew Lunn, Vivien Didelot, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Rob Herring, Krzysztof Kozlowski, George McCollister,
	Kurt Kanzenbach, Matthias Brugger, Woojung Huh, UNGLinuxDriver,
	Linus Walleij, Alvin Šipraga, Clément Léger,
	Landen Chao, DENG Qingfang, Sean Wang, Marek Vasut, John Crispin,
	devicetree, linux-kernel, linux-arm-kernel, linux-mediatek,
	linux-renesas-soc

On 12.09.2022 20:50, Vladimir Oltean wrote:
> The fact that some DSA device trees use 'label = "cpu"' for the CPU port
> is nothing but blind cargo cult copying. The 'label' property was never
> part of the DSA DT bindings for anything except the user ports, where it
> provided a hint as to what name the created netdevs should use.
> 
> DSA does use the "cpu" port label to identify a CPU port in dsa_port_parse(),
> but this is only for non-OF code paths (platform data).
> 
> The proper way to identify a CPU port is to look at whether the
> 'ethernet' phandle is present.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>

Reviewed-by: Arınç ÜNAL <arinc.unal@arinc9.com>

Arınç

> ---
>   .../devicetree/bindings/net/dsa/mediatek,mt7530.yaml | 12 +++---------
>   1 file changed, 3 insertions(+), 9 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> index f9e7b6e20b35..fa271ee16b5e 100644
> --- a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> @@ -163,9 +163,7 @@ patternProperties:
>           allOf:
>             - $ref: dsa-port.yaml#
>             - if:
> -              properties:
> -                label:
> -                  const: cpu
> +              required: [ ethernet ]
>               then:
>                 required:
>                   - phy-mode
> @@ -187,9 +185,7 @@ $defs:
>           patternProperties:
>             "^(ethernet-)?port@[0-9]+$":
>               if:
> -              properties:
> -                label:
> -                  const: cpu
> +              required: [ ethernet ]
>               then:
>                 if:
>                   properties:
> @@ -215,9 +211,7 @@ $defs:
>           patternProperties:
>             "^(ethernet-)?port@[0-9]+$":
>               if:
> -              properties:
> -                label:
> -                  const: cpu
> +              required: [ ethernet ]
>               then:
>                 if:
>                   properties:

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports
  2022-09-12 17:50 ` [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports Vladimir Oltean
  2022-09-12 18:07   ` Florian Fainelli
@ 2022-09-13  8:19   ` Arınç ÜNAL
  2022-09-13 15:51   ` Rob Herring
  2 siblings, 0 replies; 20+ messages in thread
From: Arınç ÜNAL @ 2022-09-13  8:19 UTC (permalink / raw)
  To: Vladimir Oltean, netdev
  Cc: Andrew Lunn, Vivien Didelot, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Rob Herring, Krzysztof Kozlowski, George McCollister,
	Kurt Kanzenbach, Matthias Brugger, Woojung Huh, UNGLinuxDriver,
	Linus Walleij, Alvin Šipraga, Clément Léger,
	Landen Chao, DENG Qingfang, Sean Wang, Marek Vasut, John Crispin,
	devicetree, linux-kernel, linux-arm-kernel, linux-mediatek,
	linux-renesas-soc

On 12.09.2022 20:50, Vladimir Oltean wrote:
> The common dsa-port.yaml does this (and more) since commit 2ec2fb8331af
> ("dt-bindings: net: dsa: make phylink bindings required for CPU/DSA
> ports").
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>

Reviewed-by: Arınç ÜNAL <arinc.unal@arinc9.com>

Arınç

> ---
>   Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml | 3 ---
>   1 file changed, 3 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> index fa271ee16b5e..84bb36cab518 100644
> --- a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> @@ -165,9 +165,6 @@ patternProperties:
>             - if:
>                 required: [ ethernet ]
>               then:
> -              required:
> -                - phy-mode
> -
>                 properties:
>                   reg:
>                     enum:

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
  2022-09-12 17:50 ` [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples Vladimir Oltean
  2022-09-12 18:12   ` Florian Fainelli
@ 2022-09-13  8:20   ` Arınç ÜNAL
  2022-09-13 13:31     ` Vladimir Oltean
  2022-09-13 15:54   ` Rob Herring
  2 siblings, 1 reply; 20+ messages in thread
From: Arınç ÜNAL @ 2022-09-13  8:20 UTC (permalink / raw)
  To: Vladimir Oltean, netdev
  Cc: Andrew Lunn, Vivien Didelot, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Rob Herring, Krzysztof Kozlowski, George McCollister,
	Kurt Kanzenbach, Matthias Brugger, Woojung Huh, UNGLinuxDriver,
	Linus Walleij, Alvin Šipraga, Clément Léger,
	Landen Chao, DENG Qingfang, Sean Wang, Marek Vasut, John Crispin,
	devicetree, linux-kernel, linux-arm-kernel, linux-mediatek,
	linux-renesas-soc

On 12.09.2022 20:50, Vladimir Oltean wrote:
> This is not used by the DSA dt-binding, so remove it from all examples.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>

Acked-by: Arınç ÜNAL <arinc.unal@arinc9.com>

Is there also a plan to remove this from every devicetree on mainline 
that has got this property on the CPU port?

I'd like to do the same on the DTs on OpenWrt.

Arınç

> ---
>   Documentation/devicetree/bindings/net/dsa/ar9331.txt       | 1 -
>   .../devicetree/bindings/net/dsa/arrow,xrs700x.yaml         | 1 -
>   Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml    | 2 --
>   .../devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml  | 1 -
>   Documentation/devicetree/bindings/net/dsa/lan9303.txt      | 2 --
>   Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt | 1 -
>   .../devicetree/bindings/net/dsa/mediatek,mt7530.yaml       | 7 -------
>   .../devicetree/bindings/net/dsa/microchip,ksz.yaml         | 2 --
>   Documentation/devicetree/bindings/net/dsa/qca8k.yaml       | 3 ---
>   Documentation/devicetree/bindings/net/dsa/realtek.yaml     | 2 --
>   .../devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml    | 1 -
>   .../devicetree/bindings/net/dsa/vitesse,vsc73xx.txt        | 2 --
>   12 files changed, 25 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/net/dsa/ar9331.txt b/Documentation/devicetree/bindings/net/dsa/ar9331.txt
> index 320607cbbb17..f824fdae0da2 100644
> --- a/Documentation/devicetree/bindings/net/dsa/ar9331.txt
> +++ b/Documentation/devicetree/bindings/net/dsa/ar9331.txt
> @@ -76,7 +76,6 @@ eth1: ethernet@1a000000 {
>   
>   				switch_port0: port@0 {
>   					reg = <0x0>;
> -					label = "cpu";
>   					ethernet = <&eth1>;
>   
>   					phy-mode = "gmii";
> diff --git a/Documentation/devicetree/bindings/net/dsa/arrow,xrs700x.yaml b/Documentation/devicetree/bindings/net/dsa/arrow,xrs700x.yaml
> index eb01a8f37ce4..259a0c6547f3 100644
> --- a/Documentation/devicetree/bindings/net/dsa/arrow,xrs700x.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/arrow,xrs700x.yaml
> @@ -61,7 +61,6 @@ examples:
>                   };
>                   ethernet-port@3 {
>                       reg = <3>;
> -                    label = "cpu";
>                       ethernet = <&fec1>;
>                       phy-mode = "rgmii-id";
>   
> diff --git a/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml b/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
> index 2e01371b8288..1219b830b1a4 100644
> --- a/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
> @@ -169,7 +169,6 @@ examples:
>   
>                   port@8 {
>                       reg = <8>;
> -                    label = "cpu";
>                       phy-mode = "rgmii-txid";
>                       ethernet = <&eth0>;
>                       fixed-link {
> @@ -252,7 +251,6 @@ examples:
>   
>                   port@8 {
>                       ethernet = <&amac2>;
> -                    label = "cpu";
>                       reg = <8>;
>                       phy-mode = "internal";
>   
> diff --git a/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml b/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml
> index 1ff44dd68a61..73b774eadd0b 100644
> --- a/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml
> @@ -91,7 +91,6 @@ examples:
>   
>                   port@0 {
>                       reg = <0>;
> -                    label = "cpu";
>                       ethernet = <&gmac0>;
>                       phy-mode = "mii";
>   
> diff --git a/Documentation/devicetree/bindings/net/dsa/lan9303.txt b/Documentation/devicetree/bindings/net/dsa/lan9303.txt
> index 464d6bf87605..46a732087f5c 100644
> --- a/Documentation/devicetree/bindings/net/dsa/lan9303.txt
> +++ b/Documentation/devicetree/bindings/net/dsa/lan9303.txt
> @@ -46,7 +46,6 @@ I2C managed mode:
>   
>   			port@0 { /* RMII fixed link to master */
>   				reg = <0>;
> -				label = "cpu";
>   				ethernet = <&master>;
>   			};
>   
> @@ -83,7 +82,6 @@ MDIO managed mode:
>   
>   					port@0 {
>   						reg = <0>;
> -						label = "cpu";
>   						ethernet = <&master>;
>   					};
>   
> diff --git a/Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt b/Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt
> index e3829d3e480e..8bb1eff21cb1 100644
> --- a/Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt
> +++ b/Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt
> @@ -96,7 +96,6 @@ switch@e108000 {
>   
>   		port@6 {
>   			reg = <0x6>;
> -			label = "cpu";
>   			ethernet = <&eth0>;
>   		};
>   	};
> diff --git a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> index 84bb36cab518..bc6446e1f55a 100644
> --- a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
> @@ -325,7 +325,6 @@ examples:
>   
>                   port@6 {
>                       reg = <6>;
> -                    label = "cpu";
>                       ethernet = <&gmac0>;
>                       phy-mode = "rgmii";
>   
> @@ -389,7 +388,6 @@ examples:
>   
>                   port@6 {
>                       reg = <6>;
> -                    label = "cpu";
>                       ethernet = <&gmac0>;
>                       phy-mode = "trgmii";
>   
> @@ -454,7 +452,6 @@ examples:
>   
>                   port@6 {
>                       reg = <6>;
> -                    label = "cpu";
>                       ethernet = <&gmac0>;
>                       phy-mode = "2500base-x";
>   
> @@ -521,7 +518,6 @@ examples:
>   
>                   port@6 {
>                       reg = <6>;
> -                    label = "cpu";
>                       ethernet = <&gmac0>;
>                       phy-mode = "trgmii";
>   
> @@ -610,7 +606,6 @@ examples:
>   
>                       port@6 {
>                           reg = <6>;
> -                        label = "cpu";
>                           ethernet = <&gmac0>;
>                           phy-mode = "trgmii";
>   
> @@ -699,7 +694,6 @@ examples:
>   
>                       port@6 {
>                           reg = <6>;
> -                        label = "cpu";
>                           ethernet = <&gmac0>;
>                           phy-mode = "trgmii";
>   
> @@ -787,7 +781,6 @@ examples:
>   
>                       port@6 {
>                           reg = <6>;
> -                        label = "cpu";
>                           ethernet = <&gmac0>;
>                           phy-mode = "trgmii";
>   
> diff --git a/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml b/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> index 456802affc9d..4da75b1f9533 100644
> --- a/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/microchip,ksz.yaml
> @@ -107,7 +107,6 @@ examples:
>                   };
>                   port@5 {
>                       reg = <5>;
> -                    label = "cpu";
>                       ethernet = <&eth0>;
>                       phy-mode = "rgmii";
>   
> @@ -146,7 +145,6 @@ examples:
>                   };
>                   port@6 {
>                       reg = <6>;
> -                    label = "cpu";
>                       ethernet = <&eth0>;
>                       phy-mode = "rgmii";
>   
> diff --git a/Documentation/devicetree/bindings/net/dsa/qca8k.yaml b/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
> index f3c88371d76c..978162df51f7 100644
> --- a/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/qca8k.yaml
> @@ -159,7 +159,6 @@ examples:
>   
>                   port@0 {
>                       reg = <0>;
> -                    label = "cpu";
>                       ethernet = <&gmac1>;
>                       phy-mode = "rgmii";
>   
> @@ -221,7 +220,6 @@ examples:
>   
>                   port@0 {
>                       reg = <0>;
> -                    label = "cpu";
>                       ethernet = <&gmac1>;
>                       phy-mode = "rgmii";
>   
> @@ -268,7 +266,6 @@ examples:
>   
>                   port@6 {
>                       reg = <0>;
> -                    label = "cpu";
>                       ethernet = <&gmac1>;
>                       phy-mode = "sgmii";
>   
> diff --git a/Documentation/devicetree/bindings/net/dsa/realtek.yaml b/Documentation/devicetree/bindings/net/dsa/realtek.yaml
> index 4f99aff029dc..1a7d45a8ad66 100644
> --- a/Documentation/devicetree/bindings/net/dsa/realtek.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/realtek.yaml
> @@ -189,7 +189,6 @@ examples:
>                               };
>                               port@5 {
>                                       reg = <5>;
> -                                    label = "cpu";
>                                       ethernet = <&gmac0>;
>                                       phy-mode = "rgmii";
>                                       fixed-link {
> @@ -277,7 +276,6 @@ examples:
>                               };
>                               port@6 {
>                                       reg = <6>;
> -                                    label = "cpu";
>                                       ethernet = <&fec1>;
>                                       phy-mode = "rgmii";
>                                       tx-internal-delay-ps = <2000>;
> diff --git a/Documentation/devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml b/Documentation/devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml
> index 14a1f0b4c32b..7ca9c19a157c 100644
> --- a/Documentation/devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml
> @@ -130,7 +130,6 @@ examples:
>               port@4 {
>                   reg = <4>;
>                   ethernet = <&gmac2>;
> -                label = "cpu";
>                   phy-mode = "internal";
>   
>                   fixed-link {
> diff --git a/Documentation/devicetree/bindings/net/dsa/vitesse,vsc73xx.txt b/Documentation/devicetree/bindings/net/dsa/vitesse,vsc73xx.txt
> index bbf4a13f6d75..258bef483673 100644
> --- a/Documentation/devicetree/bindings/net/dsa/vitesse,vsc73xx.txt
> +++ b/Documentation/devicetree/bindings/net/dsa/vitesse,vsc73xx.txt
> @@ -75,7 +75,6 @@ switch@0 {
>   		};
>   		vsc: port@6 {
>   			reg = <6>;
> -			label = "cpu";
>   			ethernet = <&gmac1>;
>   			phy-mode = "rgmii";
>   			fixed-link {
> @@ -117,7 +116,6 @@ switch@2,0 {
>   		};
>   		vsc: port@6 {
>   			reg = <6>;
> -			label = "cpu";
>   			ethernet = <&enet0>;
>   			phy-mode = "rgmii";
>   			fixed-link {

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
  2022-09-13  8:20   ` Arınç ÜNAL
@ 2022-09-13 13:31     ` Vladimir Oltean
  2022-09-13 14:14       ` Arınç ÜNAL
  2022-09-13 15:54       ` Rob Herring
  0 siblings, 2 replies; 20+ messages in thread
From: Vladimir Oltean @ 2022-09-13 13:31 UTC (permalink / raw)
  To: Arınç ÜNAL
  Cc: netdev, Andrew Lunn, Vivien Didelot, Florian Fainelli,
	Vladimir Oltean, David S. Miller, Eric Dumazet, Jakub Kicinski,
	Paolo Abeni, Rob Herring, Krzysztof Kozlowski,
	George McCollister, Kurt Kanzenbach, Matthias Brugger,
	Woojung Huh, UNGLinuxDriver, Linus Walleij, Alvin Šipraga,
	Clément Léger, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

On Tue, Sep 13, 2022 at 11:20:04AM +0300, Arınç ÜNAL wrote:
> Is there also a plan to remove this from every devicetree on mainline that
> has got this property on the CPU port?
> 
> I'd like to do the same on the DTs on OpenWrt.

I don't really have the time to split patches towards every individual
platform maintainer and follow up with them until such patches would get
accepted. I would encourage such an initiative coming from somebody else,
though.
_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
  2022-09-13 13:31     ` Vladimir Oltean
@ 2022-09-13 14:14       ` Arınç ÜNAL
  2022-09-13 14:32         ` Vladimir Oltean
  2022-09-13 15:54       ` Rob Herring
  1 sibling, 1 reply; 20+ messages in thread
From: Arınç ÜNAL @ 2022-09-13 14:14 UTC (permalink / raw)
  To: Vladimir Oltean
  Cc: netdev, Andrew Lunn, Vivien Didelot, Florian Fainelli,
	Vladimir Oltean, David S. Miller, Eric Dumazet, Jakub Kicinski,
	Paolo Abeni, Rob Herring, Krzysztof Kozlowski,
	George McCollister, Kurt Kanzenbach, Matthias Brugger,
	Woojung Huh, UNGLinuxDriver, Linus Walleij, Alvin Šipraga,
	Clément Léger, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

On 13.09.2022 16:31, Vladimir Oltean wrote:
> On Tue, Sep 13, 2022 at 11:20:04AM +0300, Arınç ÜNAL wrote:
>> Is there also a plan to remove this from every devicetree on mainline that
>> has got this property on the CPU port?
>>
>> I'd like to do the same on the DTs on OpenWrt.
> 
> I don't really have the time to split patches towards every individual
> platform maintainer and follow up with them until such patches would get
> accepted. I would encourage such an initiative coming from somebody else,
> though.

Understood, I think I can deal with this.

Arınç

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
  2022-09-13 14:14       ` Arınç ÜNAL
@ 2022-09-13 14:32         ` Vladimir Oltean
  0 siblings, 0 replies; 20+ messages in thread
From: Vladimir Oltean @ 2022-09-13 14:32 UTC (permalink / raw)
  To: Arınç ÜNAL
  Cc: netdev, Andrew Lunn, Vivien Didelot, Florian Fainelli,
	Vladimir Oltean, David S. Miller, Eric Dumazet, Jakub Kicinski,
	Paolo Abeni, Rob Herring, Krzysztof Kozlowski,
	George McCollister, Kurt Kanzenbach, Matthias Brugger,
	Woojung Huh, UNGLinuxDriver, Linus Walleij, Alvin Šipraga,
	Clément Léger, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

On Tue, Sep 13, 2022 at 05:14:19PM +0300, Arınç ÜNAL wrote:
> On 13.09.2022 16:31, Vladimir Oltean wrote:
> > On Tue, Sep 13, 2022 at 11:20:04AM +0300, Arınç ÜNAL wrote:
> > > Is there also a plan to remove this from every devicetree on mainline that
> > > has got this property on the CPU port?
> > > 
> > > I'd like to do the same on the DTs on OpenWrt.
> > 
> > I don't really have the time to split patches towards every individual
> > platform maintainer and follow up with them until such patches would get
> > accepted. I would encourage such an initiative coming from somebody else,
> > though.
> 
> Understood, I think I can deal with this.
> 
> Arınç

That would be great, thanks!
_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks
  2022-09-12 17:50 ` [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks Vladimir Oltean
  2022-09-12 17:59   ` Florian Fainelli
  2022-09-13  8:19   ` Arınç ÜNAL
@ 2022-09-13 15:51   ` Rob Herring
  2022-09-13 15:55   ` Arınç ÜNAL
  3 siblings, 0 replies; 20+ messages in thread
From: Rob Herring @ 2022-09-13 15:51 UTC (permalink / raw)
  To: Vladimir Oltean
  Cc: Sean Wang, Paolo Abeni, Kurt Kanzenbach, DENG Qingfang,
	Arınç ÜNAL, linux-kernel, George McCollister,
	linux-arm-kernel, linux-renesas-soc, David S. Miller,
	Florian Fainelli, Linus Walleij, Andrew Lunn, Woojung Huh,
	Eric Dumazet, Jakub Kicinski, UNGLinuxDriver,
	Clément Léger, devicetree, Krzysztof Kozlowski,
	linux-mediatek, Matthias Brugger, Rob Herring, Landen Chao,
	Vladimir Oltean, John Crispin, Vivien Didelot, Marek Vasut,
	Alvin Šipraga, netdev

On Mon, 12 Sep 2022 20:50:56 +0300, Vladimir Oltean wrote:
> The fact that some DSA device trees use 'label = "cpu"' for the CPU port
> is nothing but blind cargo cult copying. The 'label' property was never
> part of the DSA DT bindings for anything except the user ports, where it
> provided a hint as to what name the created netdevs should use.
> 
> DSA does use the "cpu" port label to identify a CPU port in dsa_port_parse(),
> but this is only for non-OF code paths (platform data).
> 
> The proper way to identify a CPU port is to look at whether the
> 'ethernet' phandle is present.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
> ---
>  .../devicetree/bindings/net/dsa/mediatek,mt7530.yaml | 12 +++---------
>  1 file changed, 3 insertions(+), 9 deletions(-)
> 

Acked-by: Rob Herring <robh@kernel.org>

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports
  2022-09-12 17:50 ` [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports Vladimir Oltean
  2022-09-12 18:07   ` Florian Fainelli
  2022-09-13  8:19   ` Arınç ÜNAL
@ 2022-09-13 15:51   ` Rob Herring
  2 siblings, 0 replies; 20+ messages in thread
From: Rob Herring @ 2022-09-13 15:51 UTC (permalink / raw)
  To: Vladimir Oltean
  Cc: Vladimir Oltean, Kurt Kanzenbach, Eric Dumazet,
	Arınç ÜNAL, Paolo Abeni, John Crispin,
	Florian Fainelli, Krzysztof Kozlowski, Matthias Brugger,
	Linus Walleij, linux-renesas-soc, linux-kernel,
	George McCollister, Vivien Didelot, Jakub Kicinski,
	linux-mediatek, Landen Chao, Andrew Lunn, UNGLinuxDriver,
	Rob Herring, Marek Vasut, netdev, Sean Wang,
	Clément Léger, Woojung Huh, devicetree,
	linux-arm-kernel, DENG Qingfang, David S. Miller,
	Alvin Šipraga

On Mon, 12 Sep 2022 20:50:57 +0300, Vladimir Oltean wrote:
> The common dsa-port.yaml does this (and more) since commit 2ec2fb8331af
> ("dt-bindings: net: dsa: make phylink bindings required for CPU/DSA
> ports").
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
> ---
>  Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml | 3 ---
>  1 file changed, 3 deletions(-)
> 

Acked-by: Rob Herring <robh@kernel.org>

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
  2022-09-13 13:31     ` Vladimir Oltean
  2022-09-13 14:14       ` Arınç ÜNAL
@ 2022-09-13 15:54       ` Rob Herring
  1 sibling, 0 replies; 20+ messages in thread
From: Rob Herring @ 2022-09-13 15:54 UTC (permalink / raw)
  To: Vladimir Oltean
  Cc: Arınç ÜNAL, netdev, Andrew Lunn, Vivien Didelot,
	Florian Fainelli, Vladimir Oltean, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Krzysztof Kozlowski,
	George McCollister, Kurt Kanzenbach, Matthias Brugger,
	Woojung Huh, UNGLinuxDriver, Linus Walleij, Alvin Šipraga,
	Clément Léger, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

On Tue, Sep 13, 2022 at 01:31:22PM +0000, Vladimir Oltean wrote:
> On Tue, Sep 13, 2022 at 11:20:04AM +0300, Arınç ÜNAL wrote:
> > Is there also a plan to remove this from every devicetree on mainline that
> > has got this property on the CPU port?
> > 
> > I'd like to do the same on the DTs on OpenWrt.
> 
> I don't really have the time to split patches towards every individual
> platform maintainer and follow up with them until such patches would get
> accepted. I would encourage such an initiative coming from somebody else,
> though.

You can always do a patch for everyone and ask soc@kernel.org 
maintainers to apply directly.

Rob

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
  2022-09-12 17:50 ` [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples Vladimir Oltean
  2022-09-12 18:12   ` Florian Fainelli
  2022-09-13  8:20   ` Arınç ÜNAL
@ 2022-09-13 15:54   ` Rob Herring
  2 siblings, 0 replies; 20+ messages in thread
From: Rob Herring @ 2022-09-13 15:54 UTC (permalink / raw)
  To: Vladimir Oltean
  Cc: Sean Wang, Jakub Kicinski, Paolo Abeni, Woojung Huh,
	Eric Dumazet, Arınç ÜNAL, Andrew Lunn,
	David S. Miller, linux-arm-kernel, Kurt Kanzenbach, John Crispin,
	linux-renesas-soc, Krzysztof Kozlowski, Linus Walleij,
	Vivien Didelot, Marek Vasut, linux-mediatek, Vladimir Oltean,
	linux-kernel, DENG Qingfang, Clément Léger, devicetree,
	Florian Fainelli, UNGLinuxDriver, netdev, Matthias Brugger,
	Rob Herring, Landen Chao, George McCollister, Alvin Šipraga

On Mon, 12 Sep 2022 20:50:58 +0300, Vladimir Oltean wrote:
> This is not used by the DSA dt-binding, so remove it from all examples.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
> ---
>  Documentation/devicetree/bindings/net/dsa/ar9331.txt       | 1 -
>  .../devicetree/bindings/net/dsa/arrow,xrs700x.yaml         | 1 -
>  Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml    | 2 --
>  .../devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml  | 1 -
>  Documentation/devicetree/bindings/net/dsa/lan9303.txt      | 2 --
>  Documentation/devicetree/bindings/net/dsa/lantiq-gswip.txt | 1 -
>  .../devicetree/bindings/net/dsa/mediatek,mt7530.yaml       | 7 -------
>  .../devicetree/bindings/net/dsa/microchip,ksz.yaml         | 2 --
>  Documentation/devicetree/bindings/net/dsa/qca8k.yaml       | 3 ---
>  Documentation/devicetree/bindings/net/dsa/realtek.yaml     | 2 --
>  .../devicetree/bindings/net/dsa/renesas,rzn1-a5psw.yaml    | 1 -
>  .../devicetree/bindings/net/dsa/vitesse,vsc73xx.txt        | 2 --
>  12 files changed, 25 deletions(-)
> 

Acked-by: Rob Herring <robh@kernel.org>

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks
  2022-09-12 17:50 ` [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks Vladimir Oltean
                     ` (2 preceding siblings ...)
  2022-09-13 15:51   ` Rob Herring
@ 2022-09-13 15:55   ` Arınç ÜNAL
  2022-09-13 16:26     ` Vladimir Oltean
  3 siblings, 1 reply; 20+ messages in thread
From: Arınç ÜNAL @ 2022-09-13 15:55 UTC (permalink / raw)
  To: Vladimir Oltean, netdev
  Cc: Andrew Lunn, Vivien Didelot, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Rob Herring, Krzysztof Kozlowski, George McCollister,
	Kurt Kanzenbach, Matthias Brugger, Woojung Huh, UNGLinuxDriver,
	Linus Walleij, Alvin Šipraga, Clément Léger,
	Landen Chao, DENG Qingfang, Sean Wang, Marek Vasut, John Crispin,
	devicetree, linux-kernel, linux-arm-kernel, linux-mediatek,
	linux-renesas-soc

On 12.09.2022 20:50, Vladimir Oltean wrote:
> The fact that some DSA device trees use 'label = "cpu"' for the CPU port
> is nothing but blind cargo cult copying. The 'label' property was never
> part of the DSA DT bindings for anything except the user ports, where it
> provided a hint as to what name the created netdevs should use.
> 
> DSA does use the "cpu" port label to identify a CPU port in dsa_port_parse(),
> but this is only for non-OF code paths (platform data).
> 
> The proper way to identify a CPU port is to look at whether the
> 'ethernet' phandle is present.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>

I realised "dt-bindings: net: dsa: mt7530:" prefix is used here instead 
of the usual "dt-bindings: net: dsa: mediatek,mt7530:". Does this matter?

Arınç

_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks
  2022-09-13 15:55   ` Arınç ÜNAL
@ 2022-09-13 16:26     ` Vladimir Oltean
  0 siblings, 0 replies; 20+ messages in thread
From: Vladimir Oltean @ 2022-09-13 16:26 UTC (permalink / raw)
  To: Arınç ÜNAL
  Cc: netdev, Andrew Lunn, Vivien Didelot, Florian Fainelli,
	Vladimir Oltean, David S. Miller, Eric Dumazet, Jakub Kicinski,
	Paolo Abeni, Rob Herring, Krzysztof Kozlowski,
	George McCollister, Kurt Kanzenbach, Matthias Brugger,
	Woojung Huh, UNGLinuxDriver, Linus Walleij, Alvin Šipraga,
	Clément Léger, Landen Chao, DENG Qingfang, Sean Wang,
	Marek Vasut, John Crispin, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-renesas-soc

On Tue, Sep 13, 2022 at 06:55:05PM +0300, Arınç ÜNAL wrote:
> On 12.09.2022 20:50, Vladimir Oltean wrote:
> > The fact that some DSA device trees use 'label = "cpu"' for the CPU port
> > is nothing but blind cargo cult copying. The 'label' property was never
> > part of the DSA DT bindings for anything except the user ports, where it
> > provided a hint as to what name the created netdevs should use.
> > 
> > DSA does use the "cpu" port label to identify a CPU port in dsa_port_parse(),
> > but this is only for non-OF code paths (platform data).
> > 
> > The proper way to identify a CPU port is to look at whether the
> > 'ethernet' phandle is present.
> > 
> > Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
> 
> I realised "dt-bindings: net: dsa: mt7530:" prefix is used here instead of
> the usual "dt-bindings: net: dsa: mediatek,mt7530:". Does this matter?

Since "mt7530" implies "mediatek", I preferred to skip it.
_______________________________________________
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] 20+ messages in thread

* Re: [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings
  2022-09-12 17:50 [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings Vladimir Oltean
                   ` (2 preceding siblings ...)
  2022-09-12 17:50 ` [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples Vladimir Oltean
@ 2022-09-20  1:10 ` patchwork-bot+netdevbpf
  3 siblings, 0 replies; 20+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-09-20  1:10 UTC (permalink / raw)
  To: Vladimir Oltean
  Cc: netdev, andrew, vivien.didelot, f.fainelli, olteanv, davem,
	edumazet, kuba, pabeni, robh+dt, krzysztof.kozlowski+dt,
	george.mccollister, kurt, matthias.bgg, woojung.huh,
	UNGLinuxDriver, linus.walleij, alsi, clement.leger, arinc.unal,
	Landen.Chao, dqfext, sean.wang, marex, john, devicetree,
	linux-kernel, linux-arm-kernel, linux-mediatek,
	linux-renesas-soc

Hello:

This series was applied to netdev/net-next.git (master)
by Jakub Kicinski <kuba@kernel.org>:

On Mon, 12 Sep 2022 20:50:55 +0300 you wrote:
> As explained in more detail in patch 1/3, label = "cpu" is not part of
> DSA's device tree bindings, yet we have some checks in the dt-schema for
> mt7530 which are written as if it was.
> 
> Reformulate those checks, and remove all occurrences of this seemingly
> used, but actually unused, property from the binding examples.
> 
> [...]

Here is the summary with links:
  - [net-next,1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks
    https://git.kernel.org/netdev/net-next/c/3f301a280078
  - [net-next,2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports
    https://git.kernel.org/netdev/net-next/c/cdd3e486d705
  - [net-next,3/3] dt-bindings: net: dsa: remove label = "cpu" from examples
    https://git.kernel.org/netdev/net-next/c/9cc115d8d6f7

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



_______________________________________________
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] 20+ messages in thread

end of thread, other threads:[~2022-09-20  1:11 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-12 17:50 [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings Vladimir Oltean
2022-09-12 17:50 ` [PATCH net-next 1/3] dt-bindings: net: dsa: mt7530: replace label = "cpu" with proper checks Vladimir Oltean
2022-09-12 17:59   ` Florian Fainelli
2022-09-13  8:19   ` Arınç ÜNAL
2022-09-13 15:51   ` Rob Herring
2022-09-13 15:55   ` Arınç ÜNAL
2022-09-13 16:26     ` Vladimir Oltean
2022-09-12 17:50 ` [PATCH net-next 2/3] dt-bindings: net: dsa: mt7530: stop requiring phy-mode on CPU ports Vladimir Oltean
2022-09-12 18:07   ` Florian Fainelli
2022-09-13  8:19   ` Arınç ÜNAL
2022-09-13 15:51   ` Rob Herring
2022-09-12 17:50 ` [PATCH net-next 3/3] dt-bindings: net: dsa: remove label = "cpu" from examples Vladimir Oltean
2022-09-12 18:12   ` Florian Fainelli
2022-09-13  8:20   ` Arınç ÜNAL
2022-09-13 13:31     ` Vladimir Oltean
2022-09-13 14:14       ` Arınç ÜNAL
2022-09-13 14:32         ` Vladimir Oltean
2022-09-13 15:54       ` Rob Herring
2022-09-13 15:54   ` Rob Herring
2022-09-20  1:10 ` [PATCH net-next 0/3] Remove label = "cpu" from DSA dt-bindings patchwork-bot+netdevbpf

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).