Skip to content

Commit 6e75ac5

Browse files
Linus Walleijgclement
authored andcommitted
ARM: dts: marvell: Fix some common switch mistakes
Fix some errors in the Marvell MV88E6xxx switch descriptions: - The top node had no address size or cells. - switch0@0 is not OK, should be ethernet-switch@0. - The ports node should be named ethernet-ports - The ethernet-ports node should have port@0 etc children, no plural "ports" in the children. - Ports should be named ethernet-port@0 etc - PHYs should be named ethernet-phy@0 etc This serves as an example of fixes needed for introducing a schema for the bindings, but the patch can simply be applied. Reviewed-by: Andrew Lunn <andrew@lunn.ch> Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Gregory CLEMENT <gregory.clement@bootlin.com>
1 parent b85ea95 commit 6e75ac5

8 files changed

Lines changed: 96 additions & 108 deletions

arch/arm/boot/dts/marvell/armada-370-rd.dts

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -149,39 +149,37 @@
149149
};
150150
};
151151

152-
switch: switch@10 {
152+
switch: ethernet-switch@10 {
153153
compatible = "marvell,mv88e6085";
154-
#address-cells = <1>;
155-
#size-cells = <0>;
156154
reg = <0x10>;
157155
interrupt-controller;
158156
#interrupt-cells = <2>;
159157

160-
ports {
158+
ethernet-ports {
161159
#address-cells = <1>;
162160
#size-cells = <0>;
163161

164-
port@0 {
162+
ethernet-port@0 {
165163
reg = <0>;
166164
label = "lan0";
167165
};
168166

169-
port@1 {
167+
ethernet-port@1 {
170168
reg = <1>;
171169
label = "lan1";
172170
};
173171

174-
port@2 {
172+
ethernet-port@2 {
175173
reg = <2>;
176174
label = "lan2";
177175
};
178176

179-
port@3 {
177+
ethernet-port@3 {
180178
reg = <3>;
181179
label = "lan3";
182180
};
183181

184-
port@5 {
182+
ethernet-port@5 {
185183
reg = <5>;
186184
ethernet = <&eth1>;
187185
phy-mode = "rgmii-id";
@@ -196,25 +194,25 @@
196194
#address-cells = <1>;
197195
#size-cells = <0>;
198196

199-
switchphy0: switchphy@0 {
197+
switchphy0: ethernet-phy@0 {
200198
reg = <0>;
201199
interrupt-parent = <&switch>;
202200
interrupts = <0 IRQ_TYPE_LEVEL_HIGH>;
203201
};
204202

205-
switchphy1: switchphy@1 {
203+
switchphy1: ethernet-phy@1 {
206204
reg = <1>;
207205
interrupt-parent = <&switch>;
208206
interrupts = <1 IRQ_TYPE_LEVEL_HIGH>;
209207
};
210208

211-
switchphy2: switchphy@2 {
209+
switchphy2: ethernet-phy@2 {
212210
reg = <2>;
213211
interrupt-parent = <&switch>;
214212
interrupts = <2 IRQ_TYPE_LEVEL_HIGH>;
215213
};
216214

217-
switchphy3: switchphy@3 {
215+
switchphy3: ethernet-phy@3 {
218216
reg = <3>;
219217
interrupt-parent = <&switch>;
220218
interrupts = <3 IRQ_TYPE_LEVEL_HIGH>;

arch/arm/boot/dts/marvell/armada-381-netgear-gs110emx.dts

Lines changed: 21 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -77,51 +77,49 @@
7777
pinctrl-0 = <&mdio_pins>;
7878
status = "okay";
7979

80-
switch@0 {
80+
ethernet-switch@0 {
8181
compatible = "marvell,mv88e6190";
82-
#address-cells = <1>;
8382
#interrupt-cells = <2>;
8483
interrupt-controller;
8584
interrupt-parent = <&gpio1>;
8685
interrupts = <7 IRQ_TYPE_LEVEL_LOW>;
8786
pinctrl-0 = <&switch_interrupt_pins>;
8887
pinctrl-names = "default";
89-
#size-cells = <0>;
9088
reg = <0>;
9189

9290
mdio {
9391
#address-cells = <1>;
9492
#size-cells = <0>;
9593

96-
switch0phy1: switch0phy1@1 {
94+
switch0phy1: ethernet-phy@1 {
9795
reg = <0x1>;
9896
};
9997

100-
switch0phy2: switch0phy2@2 {
98+
switch0phy2: ethernet-phy@2 {
10199
reg = <0x2>;
102100
};
103101

104-
switch0phy3: switch0phy3@3 {
102+
switch0phy3: ethernet-phy@3 {
105103
reg = <0x3>;
106104
};
107105

108-
switch0phy4: switch0phy4@4 {
106+
switch0phy4: ethernet-phy@4 {
109107
reg = <0x4>;
110108
};
111109

112-
switch0phy5: switch0phy5@5 {
110+
switch0phy5: ethernet-phy@5 {
113111
reg = <0x5>;
114112
};
115113

116-
switch0phy6: switch0phy6@6 {
114+
switch0phy6: ethernet-phy@6 {
117115
reg = <0x6>;
118116
};
119117

120-
switch0phy7: switch0phy7@7 {
118+
switch0phy7: ethernet-phy@7 {
121119
reg = <0x7>;
122120
};
123121

124-
switch0phy8: switch0phy8@8 {
122+
switch0phy8: ethernet-phy@8 {
125123
reg = <0x8>;
126124
};
127125
};
@@ -142,11 +140,11 @@
142140
};
143141
};
144142

145-
ports {
143+
ethernet-ports {
146144
#address-cells = <1>;
147145
#size-cells = <0>;
148146

149-
port@0 {
147+
ethernet-port@0 {
150148
ethernet = <&eth0>;
151149
phy-mode = "rgmii";
152150
reg = <0>;
@@ -158,63 +156,63 @@
158156
};
159157
};
160158

161-
port@1 {
159+
ethernet-port@1 {
162160
label = "lan1";
163161
phy-handle = <&switch0phy1>;
164162
reg = <1>;
165163
};
166164

167-
port@2 {
165+
ethernet-port@2 {
168166
label = "lan2";
169167
phy-handle = <&switch0phy2>;
170168
reg = <2>;
171169
};
172170

173-
port@3 {
171+
ethernet-port@3 {
174172
label = "lan3";
175173
phy-handle = <&switch0phy3>;
176174
reg = <3>;
177175
};
178176

179-
port@4 {
177+
ethernet-port@4 {
180178
label = "lan4";
181179
phy-handle = <&switch0phy4>;
182180
reg = <4>;
183181
};
184182

185-
port@5 {
183+
ethernet-port@5 {
186184
label = "lan5";
187185
phy-handle = <&switch0phy5>;
188186
reg = <5>;
189187
};
190188

191-
port@6 {
189+
ethernet-port@6 {
192190
label = "lan6";
193191
phy-handle = <&switch0phy6>;
194192
reg = <6>;
195193
};
196194

197-
port@7 {
195+
ethernet-port@7 {
198196
label = "lan7";
199197
phy-handle = <&switch0phy7>;
200198
reg = <7>;
201199
};
202200

203-
port@8 {
201+
ethernet-port@8 {
204202
label = "lan8";
205203
phy-handle = <&switch0phy8>;
206204
reg = <8>;
207205
};
208206

209-
port@9 {
207+
ethernet-port@9 {
210208
/* 88X3310P external phy */
211209
label = "lan9";
212210
phy-handle = <&phy1>;
213211
phy-mode = "xaui";
214212
reg = <9>;
215213
};
216214

217-
port@a {
215+
ethernet-port@a {
218216
/* 88X3310P external phy */
219217
label = "lan10";
220218
phy-handle = <&phy2>;

arch/arm/boot/dts/marvell/armada-385-clearfog-gtr-l8.dts

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,66 +7,66 @@
77
};
88

99
&mdio {
10-
switch0: switch0@4 {
10+
switch0: ethernet-switch@4 {
1111
compatible = "marvell,mv88e6190";
1212
reg = <4>;
1313
pinctrl-names = "default";
1414
pinctrl-0 = <&cf_gtr_switch_reset_pins>;
1515
reset-gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
1616

17-
ports {
17+
ethernet-ports {
1818
#address-cells = <1>;
1919
#size-cells = <0>;
2020

21-
port@1 {
21+
ethernet-port@1 {
2222
reg = <1>;
2323
label = "lan8";
2424
phy-handle = <&switch0phy0>;
2525
};
2626

27-
port@2 {
27+
ethernet-port@2 {
2828
reg = <2>;
2929
label = "lan7";
3030
phy-handle = <&switch0phy1>;
3131
};
3232

33-
port@3 {
33+
ethernet-port@3 {
3434
reg = <3>;
3535
label = "lan6";
3636
phy-handle = <&switch0phy2>;
3737
};
3838

39-
port@4 {
39+
ethernet-port@4 {
4040
reg = <4>;
4141
label = "lan5";
4242
phy-handle = <&switch0phy3>;
4343
};
4444

45-
port@5 {
45+
ethernet-port@5 {
4646
reg = <5>;
4747
label = "lan4";
4848
phy-handle = <&switch0phy4>;
4949
};
5050

51-
port@6 {
51+
ethernet-port@6 {
5252
reg = <6>;
5353
label = "lan3";
5454
phy-handle = <&switch0phy5>;
5555
};
5656

57-
port@7 {
57+
ethernet-port@7 {
5858
reg = <7>;
5959
label = "lan2";
6060
phy-handle = <&switch0phy6>;
6161
};
6262

63-
port@8 {
63+
ethernet-port@8 {
6464
reg = <8>;
6565
label = "lan1";
6666
phy-handle = <&switch0phy7>;
6767
};
6868

69-
port@10 {
69+
ethernet-port@10 {
7070
reg = <10>;
7171
phy-mode = "2500base-x";
7272

@@ -83,35 +83,35 @@
8383
#address-cells = <1>;
8484
#size-cells = <0>;
8585

86-
switch0phy0: switch0phy0@1 {
86+
switch0phy0: ethernet-phy@1 {
8787
reg = <0x1>;
8888
};
8989

90-
switch0phy1: switch0phy1@2 {
90+
switch0phy1: ethernet-phy@2 {
9191
reg = <0x2>;
9292
};
9393

94-
switch0phy2: switch0phy2@3 {
94+
switch0phy2: ethernet-phy@3 {
9595
reg = <0x3>;
9696
};
9797

98-
switch0phy3: switch0phy3@4 {
98+
switch0phy3: ethernet-phy@4 {
9999
reg = <0x4>;
100100
};
101101

102-
switch0phy4: switch0phy4@5 {
102+
switch0phy4: ethernet-phy@5 {
103103
reg = <0x5>;
104104
};
105105

106-
switch0phy5: switch0phy5@6 {
106+
switch0phy5: ethernet-phy@6 {
107107
reg = <0x6>;
108108
};
109109

110-
switch0phy6: switch0phy6@7 {
110+
switch0phy6: ethernet-phy@7 {
111111
reg = <0x7>;
112112
};
113113

114-
switch0phy7: switch0phy7@8 {
114+
switch0phy7: ethernet-phy@8 {
115115
reg = <0x8>;
116116
};
117117
};

0 commit comments

Comments
 (0)