ramips: add support for Netgear R6080
[openwrt/staging/dedeckeh.git] / target / linux / ramips / dts / mt7628an_netgear_r6120.dts
1 /dts-v1/;
2
3 #include "mt7628an.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "netgear,r6120", "mediatek,mt7628an-soc";
10 model = "Netgear R6120";
11
12 aliases {
13 led-boot = &led_power;
14 led-failsafe = &led_power;
15 led-running = &led_power;
16 led-upgrade = &led_power;
17 label-mac-device = &ethernet;
18 };
19
20 keys {
21 compatible = "gpio-keys";
22
23 reset {
24 label = "reset";
25 gpios = <&gpio 38 GPIO_ACTIVE_LOW>;
26 linux,code = <KEY_RESTART>;
27 };
28 };
29
30 leds {
31 compatible = "gpio-leds";
32
33 lan {
34 label = "r6120:green:lan";
35 gpios = <&gpio 44 GPIO_ACTIVE_LOW>;
36 };
37
38 led_power: power {
39 label = "r6120:green:power";
40 gpios = <&gpio 43 GPIO_ACTIVE_LOW>;
41 };
42
43 wlan2g_green {
44 label = "r6120:green:wlan2g";
45 gpios = <&gpio 42 GPIO_ACTIVE_LOW>;
46 linux,default-trigger = "phy0tpt";
47 };
48
49 wlan2g_orange {
50 label = "r6120:orange:wlan2g";
51 gpios = <&gpio 41 GPIO_ACTIVE_LOW>;
52 };
53
54 wan_green {
55 label = "r6120:green:wan";
56 gpios = <&gpio 40 GPIO_ACTIVE_LOW>;
57 };
58
59 wan_orange {
60 label = "r6120:orange:wan";
61 gpios = <&gpio 39 GPIO_ACTIVE_LOW>;
62 };
63 };
64
65 usb-regulator {
66 compatible = "regulator-fixed";
67
68 regulator-name = "USB-power";
69 gpio = <&gpio 45 GPIO_ACTIVE_HIGH>;
70 regulator-min-microvolt = <5000000>;
71 regulator-max-microvolt = <5000000>;
72 enable-active-high;
73
74 regulator-always-on;
75 };
76 };
77
78 &state_default {
79 gpio {
80 groups = "p0led_an", "p1led_an", "p2led_an",
81 "p3led_an", "p4led_an", "wdt",
82 "wled_an", "uart1";
83 function = "gpio";
84 };
85 };
86
87 &spi0 {
88 status = "okay";
89
90 flash@0 {
91 compatible = "jedec,spi-nor";
92 reg = <0>;
93 spi-max-frequency = <10000000>;
94
95 partitions {
96 compatible = "fixed-partitions";
97 #address-cells = <1>;
98 #size-cells = <1>;
99
100 partition@0 {
101 label = "u-boot";
102 reg = <0x0 0x40000>;
103 read-only;
104 };
105
106 factory: partition@40000 {
107 label = "factory";
108 reg = <0x40000 0x20000>;
109 read-only;
110 };
111
112 partition@60000 {
113 label = "nvram";
114 reg = <0x60000 0x30000>;
115 read-only;
116 };
117
118 partition@90000 {
119 compatible = "denx,uimage";
120 label = "firmware";
121 reg = <0x90000 0xf60000>;
122 };
123
124 partition@ff0000 {
125 label = "reserved";
126 reg = <0xff0000 0x10000>;
127 read-only;
128 };
129 };
130 };
131 };
132
133 &wmac {
134 status = "okay";
135 };
136
137 &ethernet {
138 mtd-mac-address = <&factory 0x4>;
139 };
140
141 &pcie {
142 status = "okay";
143 };
144
145 &pcie0 {
146 wifi@0,0 {
147 reg = <0x0000 0 0 0 0>;
148 mediatek,mtd-eeprom = <&factory 0x8000>;
149 ieee80211-freq-limit = <5000000 6000000>;
150 mtd-mac-address = <&factory 0x4>;
151 mtd-mac-address-increment = <(2)>;
152 };
153 };