ramips: convert mtd-mac-address to nvmem implementation
[openwrt/staging/dedeckeh.git] / target / linux / ramips / dts / mt7628an_mercury_mac1200r-v2.dts
1 #include "mt7628an.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "mercury,mac1200r-v2", "mediatek,mt7628an-soc";
8 model = "Mercury MAC1200R v2";
9
10 aliases {
11 led-boot = &led_status;
12 led-failsafe = &led_status;
13 led-running = &led_status;
14 led-upgrade = &led_status;
15 };
16
17 leds {
18 compatible = "gpio-leds";
19
20 led_status: status {
21 label = "green:status";
22 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
23 };
24 };
25 };
26
27 &spi0 {
28 status = "okay";
29
30 flash@0 {
31 compatible = "jedec,spi-nor";
32 reg = <0>;
33 spi-max-frequency = <10000000>;
34
35 partitions {
36 compatible = "fixed-partitions";
37 #address-cells = <1>;
38 #size-cells = <1>;
39
40 partition@0 {
41 label = "u-boot";
42 reg = <0x0 0x1d800>;
43 };
44
45 factory: partition@1d800 {
46 label = "factory_info";
47 reg = <0x1d800 0x800>;
48 read-only;
49 };
50
51 art: partition@1e000 {
52 label = "art";
53 reg = <0x1e000 0x2000>;
54 read-only;
55 };
56
57 partition@20000 {
58 label = "config";
59 reg = <0x20000 0x10000>;
60 };
61
62 partition@30000 {
63 label = "u-boot2";
64 reg = <0x30000 0x10000>;
65 };
66
67 partition@40000 {
68 compatible = "denx,uimage";
69 label = "firmware";
70 reg = <0x40000 0x7c0000>;
71 };
72 };
73 };
74 };
75
76 &ethernet {
77 pinctrl-names = "default";
78 nvmem-cells = <&macaddr_factory_d>;
79 nvmem-cell-names = "mac-address";
80 };
81
82 &esw {
83 mediatek,portmap = <0x2f>;
84 };
85
86 &wmac {
87 status = "okay";
88 ralink,mtd-eeprom = <&art 0x0>;
89 };
90
91 &pcie {
92 status = "okay";
93 };
94
95 &pcie0 {
96 mt76@0,0 {
97 reg = <0x0000 0 0 0 0>;
98 mediatek,mtd-eeprom = <&art 0x1000>;
99 ieee80211-freq-limit = <5000000 6000000>;
100 };
101 };
102
103 &factory {
104 compatible = "nvmem-cells";
105 #address-cells = <1>;
106 #size-cells = <1>;
107
108 macaddr_factory_d: macaddr@d {
109 reg = <0xd 0x6>;
110 };
111 };