lantiq: convert mtd-mac-address to nvmem implementation
[openwrt/openwrt.git] / target / linux / lantiq / files / arch / mips / boot / dts / lantiq / danube_arcadyan_arv7510pw22.dts
1 #include "danube.dtsi"
2
3 #include <dt-bindings/input/input.h>
4
5 / {
6 compatible = "arcadyan,arv7510pw22", "lantiq,xway", "lantiq,danube";
7 model = "Astoria Networks ARV7510PW22";
8
9 chosen {
10 bootargs = "console=ttyLTQ0,115200";
11 };
12
13 aliases {
14 led-boot = &power;
15 led-failsafe = &power;
16 led-running = &power;
17 led-upgrade = &power;
18
19 led-dsl = &internet;
20 led-usb = &umts;
21 led-wifi = &wlan;
22 };
23
24 memory@0 {
25 device_type = "memory";
26 reg = <0x0 0x4000000>;
27 };
28
29 keys {
30 compatible = "gpio-keys-polled";
31 poll-interval = <100>;
32
33 rfkill {
34 label = "rfkill";
35 gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
36 linux,code = <KEY_RFKILL>;
37 };
38 restart {
39 label = "restart";
40 gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
41 linux,code = <KEY_POWER>;
42 };
43 reset {
44 label = "reset";
45 gpios = <&gpio 28 GPIO_ACTIVE_LOW>;
46 linux,code = <KEY_RESTART>;
47 };
48 };
49
50 leds {
51 compatible = "gpio-leds";
52 power: power {
53 label = "power";
54 gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
55 default-state = "keep";
56 };
57 internet: internet {
58 label = "internet";
59 gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
60 };
61 wlan: wlan {
62 label = "wlan";
63 gpios = <&gpio 10 GPIO_ACTIVE_LOW>;
64 };
65 umts: 3g {
66 label = "3g";
67 gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
68 };
69 message {
70 label = "message";
71 gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
72 };
73 };
74
75 usb_vbus: regulator-usb-vbus {
76 compatible = "regulator-fixed";
77
78 regulator-name = "USB_VBUS";
79
80 regulator-min-microvolt = <5000000>;
81 regulator-max-microvolt = <5000000>;
82
83 gpio = <&gpio 8 GPIO_ACTIVE_HIGH>;
84 enable-active-high;
85 };
86 };
87
88 &gpio {
89 pinctrl-names = "default";
90 pinctrl-0 = <&state_default>;
91
92 state_default: pinmux {
93 exin {
94 lantiq,groups = "exin1";
95 lantiq,function = "exin";
96 lantiq,pull = <2>;
97 lantiq,output = <0>;
98 };
99 pci_rst {
100 lantiq,pins = "io21";
101 lantiq,pull = <2>;
102 lantiq,output = <1>;
103 };
104 pins_out {
105 lantiq,pins = "io2", "io4", "io8", "io9", "io10", "io15", "io20";
106 lantiq,output = <1>;
107 };
108 pins_in {
109 lantiq,pins = "io11", "io12", "io28";
110 lantiq,open-drain = <1>;
111 lantiq,pull = <2>;
112 lantiq,output = <0>;
113 };
114 };
115 };
116
117 &gsw {
118 /* Switch reset 19 */
119 phy-mode = "mii";
120 nvmem-cells = <&macaddr_boardconfig_16>;
121 nvmem-cell-names = "mac-address";
122 };
123
124 &localbus {
125 flash@0 {
126 compatible = "lantiq,nor";
127 bank-width = <2>;
128 reg = <0 0x0 0x1000000>;
129
130 partitions {
131 compatible = "fixed-partitions";
132 #address-cells = <1>;
133 #size-cells = <1>;
134
135 partition@0 {
136 label = "uboot";
137 reg = <0x00000 0x40000>;
138 read-only;
139 };
140
141 partition@40000 {
142 label = "u-boot-env";
143 reg = <0x40000 0x20000>;
144 read-only;
145 };
146
147 partition@60000 {
148 label = "firmware";
149 reg = <0x60000 0xf80000>;
150 };
151
152 boardconfig: partition@fe0000 {
153 label = "board_config";
154 reg = <0xfe0000 0x20000>;
155 read-only;
156 };
157 };
158 };
159 };
160
161 &pci0 {
162 status = "okay";
163
164 pinctrl-0 = <&pci_gnt1_pins>, <&pci_req1_pins>, <&pci_req2_pins>;
165 pinctrl-names = "default";
166
167 lantiq,external-clock;
168 interrupt-map = <
169 0x7000 0 0 1 &icu0 30
170 0x7800 0 0 1 &icu0 135
171 0x7800 0 0 2 &icu0 135
172 0x7800 0 0 3 &icu0 135
173 >;
174 gpio-reset = <&gpio 21 GPIO_ACTIVE_HIGH>;
175 req-mask = <0x3>;
176
177 wifi@1814,3592 {
178 compatible = "pci1814,3592";
179 reg = <0x7000 0 0 0 0>;
180 ralink,mtd-eeprom = <&boardconfig 0x410>;
181 ralink,mtd-eeprom-swap;
182 };
183 };
184
185 &usb_phy {
186 status = "okay";
187 };
188
189 &usb {
190 status = "okay";
191 vbus-supply = <&usb_vbus>;
192 };
193
194 &vmmc {
195 status = "okay";
196 gpios = <&gpio 9 GPIO_ACTIVE_HIGH>;
197 };
198
199 &boardconfig {
200 compatible = "nvmem-cells";
201 #address-cells = <1>;
202 #size-cells = <1>;
203
204 macaddr_boardconfig_16: macaddr@16 {
205 reg = <0x16 0x6>;
206 };
207 };