mediatek: mt7622: modernize Linksys E8450 / Belkin RT3200 UBI build
[openwrt/staging/jow.git] / target / linux / mediatek / dts / mt7622-linksys-e8450-ubi.dts
1 // SPDX-License-Identifier: (GPL-2.0-only OR MIT)
2
3 /dts-v1/;
4 #include "mt7622-linksys-e8450.dtsi"
5
6 / {
7 model = "Linksys E8450 (UBI)";
8 compatible = "linksys,e8450-ubi", "mediatek,mt7622";
9
10 aliases {
11 label-mac-device = &wan;
12 };
13
14 chosen {
15 rootdisk = <&ubi_rootfs>;
16 bootargs = "earlycon=uart8250,mmio32,0x11002000 console=ttyS0,115200n1 swiotlb=512 ubi.block=0,fit root=/dev/fit0";
17 };
18 };
19
20 &snand {
21 partitions {
22 compatible = "fixed-partitions";
23 #address-cells = <1>;
24 #size-cells = <1>;
25
26 partition@0 {
27 label = "bl2";
28 reg = <0x0 0x80000>;
29 read-only;
30 };
31
32 partition@80000 {
33 label = "ubi";
34 reg = <0x80000 0x7f80000>;
35 compatible = "linux,ubi";
36
37 volumes {
38 ubi-volume-ubootenv {
39 volname = "ubootenv";
40 nvmem-layout {
41 compatible = "u-boot,env-redundant-bool-layout";
42 };
43 };
44
45 ubi-volume-ubootenv2 {
46 volname = "ubootenv2";
47 nvmem-layout {
48 compatible = "u-boot,env-redundant-bool-layout";
49 };
50 };
51
52 ubi_rootfs: ubi-volume-fit {
53 volname = "fit";
54 };
55
56 ubi_factory: ubi-volume-factory {
57 volname = "factory";
58 };
59 };
60 };
61 };
62 };
63
64 &ubi_factory {
65 nvmem-layout {
66 compatible = "fixed-layout";
67 #address-cells = <1>;
68 #size-cells = <1>;
69
70 eeprom_factory_0: eeprom@0 {
71 reg = <0x0 0x4da8>; /* actual length 0x400 */
72 };
73
74 eeprom_factory_5000: eeprom@5000 {
75 reg = <0x5000 0xe00>;
76 };
77
78 macaddr_factory_7fff4: macaddr@7fff4 {
79 reg = <0x7fff4 0x6>;
80 };
81
82 macaddr_factory_7fffa: macaddr@7fffa {
83 reg = <0x7fffa 0x6>;
84 };
85 };
86 };
87
88 &wmac {
89 nvmem-cells = <&eeprom_factory_0>;
90 nvmem-cell-names = "eeprom";
91 status = "okay";
92 };
93
94 &wmac1 {
95 nvmem-cells = <&eeprom_factory_5000>;
96 nvmem-cell-names = "eeprom";
97 };
98
99 &gmac0 {
100 nvmem-cells = <&macaddr_factory_7fff4>;
101 nvmem-cell-names = "mac-address";
102 };
103
104 &wan {
105 nvmem-cells = <&macaddr_factory_7fffa>;
106 nvmem-cell-names = "mac-address";
107 };