Skip to content

Commit 627d3ca

Browse files
committed
riscv: dts: microchip: refactor icicle kit device tree
Assorted minor changes to the MPFS/Icicle kit device tree: - rename serial to mmuart to match microchip documentation - move phy0 inside mac1 node to match phy configuration - add labels where missing (cpus, cache controller) - add missing address cells & interrupts to MACs Signed-off-by: Conor Dooley <conor.dooley@microchip.com> Acked-by: Palmer Dabbelt <palmer@rivosinc.com> Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
1 parent 6b1748b commit 627d3ca

2 files changed

Lines changed: 52 additions & 50 deletions

File tree

arch/riscv/boot/dts/microchip/microchip-mpfs-icicle-kit.dts

Lines changed: 20 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// SPDX-License-Identifier: (GPL-2.0 OR MIT)
2-
/* Copyright (c) 2020 Microchip Technology Inc */
2+
/* Copyright (c) 2020-2021 Microchip Technology Inc */
33

44
/dts-v1/;
55

@@ -15,11 +15,11 @@
1515
compatible = "microchip,mpfs-icicle-kit", "microchip,mpfs";
1616

1717
aliases {
18-
ethernet0 = &emac1;
19-
serial0 = &serial0;
20-
serial1 = &serial1;
21-
serial2 = &serial2;
22-
serial3 = &serial3;
18+
ethernet0 = &mac1;
19+
serial0 = &mmuart0;
20+
serial1 = &mmuart1;
21+
serial2 = &mmuart2;
22+
serial3 = &mmuart3;
2323
};
2424

2525
chosen {
@@ -44,19 +44,19 @@
4444
clock-frequency = <600000000>;
4545
};
4646

47-
&serial0 {
47+
&mmuart0 {
4848
status = "okay";
4949
};
5050

51-
&serial1 {
51+
&mmuart1 {
5252
status = "okay";
5353
};
5454

55-
&serial2 {
55+
&mmuart2 {
5656
status = "okay";
5757
};
5858

59-
&serial3 {
59+
&mmuart3 {
6060
status = "okay";
6161
};
6262

@@ -66,7 +66,10 @@
6666
bus-width = <4>;
6767
disable-wp;
6868
cap-sd-highspeed;
69+
cap-mmc-highspeed;
6970
card-detect-delay = <200>;
71+
mmc-ddr-1_8v;
72+
mmc-hs200-1_8v;
7073
sd-uhs-sdr12;
7174
sd-uhs-sdr25;
7275
sd-uhs-sdr50;
@@ -77,22 +80,22 @@
7780
status = "okay";
7881
};
7982

80-
&emac0 {
83+
&mac0 {
8184
phy-mode = "sgmii";
8285
phy-handle = <&phy0>;
83-
phy0: ethernet-phy@8 {
84-
reg = <8>;
85-
ti,fifo-depth = <0x01>;
86-
};
8786
};
8887

89-
&emac1 {
88+
&mac1 {
9089
status = "okay";
9190
phy-mode = "sgmii";
9291
phy-handle = <&phy1>;
9392
phy1: ethernet-phy@9 {
9493
reg = <9>;
95-
ti,fifo-depth = <0x01>;
94+
ti,fifo-depth = <0x1>;
95+
};
96+
phy0: ethernet-phy@8 {
97+
reg = <8>;
98+
ti,fifo-depth = <0x1>;
9699
};
97100
};
98101

arch/riscv/boot/dts/microchip/microchip-mpfs.dtsi

Lines changed: 32 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// SPDX-License-Identifier: (GPL-2.0 OR MIT)
2-
/* Copyright (c) 2020 Microchip Technology Inc */
2+
/* Copyright (c) 2020-2021 Microchip Technology Inc */
33

44
/dts-v1/;
55
#include "dt-bindings/clock/microchip,mpfs-clock.h"
@@ -15,7 +15,7 @@
1515
#address-cells = <1>;
1616
#size-cells = <0>;
1717

18-
cpu@0 {
18+
cpu0: cpu@0 {
1919
compatible = "sifive,e51", "sifive,rocket0", "riscv";
2020
device_type = "cpu";
2121
i-cache-block-size = <64>;
@@ -33,7 +33,7 @@
3333
};
3434
};
3535

36-
cpu@1 {
36+
cpu1: cpu@1 {
3737
compatible = "sifive,u54-mc", "sifive,rocket0", "riscv";
3838
d-cache-block-size = <64>;
3939
d-cache-sets = <64>;
@@ -60,7 +60,7 @@
6060
};
6161
};
6262

63-
cpu@2 {
63+
cpu2: cpu@2 {
6464
compatible = "sifive,u54-mc", "sifive,rocket0", "riscv";
6565
d-cache-block-size = <64>;
6666
d-cache-sets = <64>;
@@ -87,7 +87,7 @@
8787
};
8888
};
8989

90-
cpu@3 {
90+
cpu3: cpu@3 {
9191
compatible = "sifive,u54-mc", "sifive,rocket0", "riscv";
9292
d-cache-block-size = <64>;
9393
d-cache-sets = <64>;
@@ -114,7 +114,7 @@
114114
};
115115
};
116116

117-
cpu@4 {
117+
cpu4: cpu@4 {
118118
compatible = "sifive,u54-mc", "sifive,rocket0", "riscv";
119119
d-cache-block-size = <64>;
120120
d-cache-sets = <64>;
@@ -152,19 +152,19 @@
152152
compatible = "simple-bus";
153153
ranges;
154154

155-
cache-controller@2010000 {
155+
cctrllr: cache-controller@2010000 {
156156
compatible = "sifive,fu540-c000-ccache", "cache";
157+
reg = <0x0 0x2010000 0x0 0x1000>;
157158
cache-block-size = <64>;
158159
cache-level = <2>;
159160
cache-sets = <1024>;
160161
cache-size = <2097152>;
161162
cache-unified;
162163
interrupt-parent = <&plic>;
163164
interrupts = <1>, <2>, <3>;
164-
reg = <0x0 0x2010000 0x0 0x1000>;
165165
};
166166

167-
clint@2000000 {
167+
clint: clint@2000000 {
168168
compatible = "sifive,fu540-c000-clint", "sifive,clint0";
169169
reg = <0x0 0x2000000 0x0 0xC000>;
170170
interrupts-extended = <&cpu0_intc 3>, <&cpu0_intc 7>,
@@ -174,6 +174,15 @@
174174
<&cpu4_intc 3>, <&cpu4_intc 7>;
175175
};
176176

177+
dma@3000000 {
178+
compatible = "sifive,fu540-c000-pdma";
179+
reg = <0x0 0x3000000 0x0 0x8000>;
180+
interrupt-parent = <&plic>;
181+
interrupts = <23>, <24>, <25>, <26>, <27>, <28>, <29>,
182+
<30>;
183+
#dma-cells = <1>;
184+
};
185+
177186
plic: interrupt-controller@c000000 {
178187
#interrupt-cells = <1>;
179188
compatible = "sifive,fu540-c000-plic", "sifive,plic-1.0.0";
@@ -187,23 +196,14 @@
187196
riscv,ndev = <186>;
188197
};
189198

190-
dma@3000000 {
191-
compatible = "sifive,fu540-c000-pdma";
192-
reg = <0x0 0x3000000 0x0 0x8000>;
193-
interrupt-parent = <&plic>;
194-
interrupts = <23>, <24>, <25>, <26>, <27>, <28>, <29>,
195-
<30>;
196-
#dma-cells = <1>;
197-
};
198-
199199
clkcfg: clkcfg@20002000 {
200200
compatible = "microchip,mpfs-clkcfg";
201201
reg = <0x0 0x20002000 0x0 0x1000>;
202202
clocks = <&refclk>;
203203
#clock-cells = <1>;
204204
};
205205

206-
serial0: serial@20000000 {
206+
mmuart0: serial@20000000 {
207207
compatible = "ns16550a";
208208
reg = <0x0 0x20000000 0x0 0x400>;
209209
reg-io-width = <4>;
@@ -215,7 +215,7 @@
215215
status = "disabled";
216216
};
217217

218-
serial1: serial@20100000 {
218+
mmuart1: serial@20100000 {
219219
compatible = "ns16550a";
220220
reg = <0x0 0x20100000 0x0 0x400>;
221221
reg-io-width = <4>;
@@ -227,7 +227,7 @@
227227
status = "disabled";
228228
};
229229

230-
serial2: serial@20102000 {
230+
mmuart2: serial@20102000 {
231231
compatible = "ns16550a";
232232
reg = <0x0 0x20102000 0x0 0x400>;
233233
reg-io-width = <4>;
@@ -239,7 +239,7 @@
239239
status = "disabled";
240240
};
241241

242-
serial3: serial@20104000 {
242+
mmuart3: serial@20104000 {
243243
compatible = "ns16550a";
244244
reg = <0x0 0x20104000 0x0 0x400>;
245245
reg-io-width = <4>;
@@ -256,37 +256,36 @@
256256
compatible = "microchip,mpfs-sd4hc", "cdns,sd4hc";
257257
reg = <0x0 0x20008000 0x0 0x1000>;
258258
interrupt-parent = <&plic>;
259-
interrupts = <88>, <89>;
259+
interrupts = <88>;
260260
clocks = <&clkcfg CLK_MMC>;
261261
max-frequency = <200000000>;
262262
status = "disabled";
263263
};
264264

265-
emac0: ethernet@20110000 {
265+
mac0: ethernet@20110000 {
266266
compatible = "cdns,macb";
267267
reg = <0x0 0x20110000 0x0 0x2000>;
268+
#address-cells = <1>;
269+
#size-cells = <0>;
268270
interrupt-parent = <&plic>;
269-
interrupts = <64>, <65>, <66>, <67>;
271+
interrupts = <64>, <65>, <66>, <67>, <68>, <69>;
270272
local-mac-address = [00 00 00 00 00 00];
271273
clocks = <&clkcfg CLK_MAC0>, <&clkcfg CLK_AHB>;
272274
clock-names = "pclk", "hclk";
273275
status = "disabled";
274-
#address-cells = <1>;
275-
#size-cells = <0>;
276276
};
277277

278-
emac1: ethernet@20112000 {
278+
mac1: ethernet@20112000 {
279279
compatible = "cdns,macb";
280280
reg = <0x0 0x20112000 0x0 0x2000>;
281+
#address-cells = <1>;
282+
#size-cells = <0>;
281283
interrupt-parent = <&plic>;
282-
interrupts = <70>, <71>, <72>, <73>;
284+
interrupts = <70>, <71>, <72>, <73>, <74>, <75>;
283285
local-mac-address = [00 00 00 00 00 00];
284286
clocks = <&clkcfg CLK_MAC1>, <&clkcfg CLK_AHB>;
285-
status = "disabled";
286287
clock-names = "pclk", "hclk";
287-
#address-cells = <1>;
288-
#size-cells = <0>;
288+
status = "disabled";
289289
};
290-
291290
};
292291
};

0 commit comments

Comments
 (0)