ramips: add support for I-O DATA WNPR2600G
[oweals/openwrt.git] / target / linux / ramips / dts / mt7621_dlink_dir-860l-b1.dts
1 /dts-v1/;
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9         compatible = "dlink,dir-860l-b1", "mediatek,mt7621-soc";
10         model = "D-Link DIR-860L B1";
11
12         aliases {
13                 led-boot = &led_power_green;
14                 led-failsafe = &led_power_green;
15                 led-running = &led_power_green;
16                 led-upgrade = &led_power_green;
17                 label-mac-device = &wifi1;
18         };
19
20         chosen {
21                 bootargs = "console=ttyS0,57600";
22         };
23
24         leds {
25                 compatible = "gpio-leds";
26
27                 power {
28                         label = "dir-860l-b1:orange:power";
29                         gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
30                 };
31
32                 led_power_green: power2 {
33                         label = "dir-860l-b1:green:power";
34                         gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
35                 };
36
37                 net {
38                         label = "dir-860l-b1:orange:net";
39                         gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
40                 };
41
42                 net2 {
43                         label = "dir-860l-b1:green:net";
44                         gpios = <&gpio0 16 GPIO_ACTIVE_LOW>;
45                 };
46         };
47
48         keys {
49                 compatible = "gpio-keys-polled";
50                 poll-interval = <20>;
51
52                 reset {
53                         label = "reset";
54                         gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
55                         linux,code = <KEY_RESTART>;
56                 };
57
58                 wps {
59                         label = "wps";
60                         gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
61                         linux,code = <KEY_WPS_BUTTON>;
62                 };
63         };
64 };
65
66 &spi0 {
67         status = "okay";
68
69         m25p80@0 {
70                 compatible = "jedec,spi-nor";
71                 reg = <0>;
72                 spi-max-frequency = <10000000>;
73
74                 partitions {
75                         compatible = "fixed-partitions";
76                         #address-cells = <1>;
77                         #size-cells = <1>;
78
79                         partition@0 {
80                                 label = "u-boot";
81                                 reg = <0x0 0x30000>;
82                                 read-only;
83                         };
84
85                         partition@30000 {
86                                 label = "u-boot-env";
87                                 reg = <0x30000 0x4000>;
88                                 read-only;
89                         };
90
91                         radio: partition@34000 {
92                                 label = "radio";
93                                 reg = <0x34000 0x4000>;
94                                 read-only;
95                         };
96
97                         factory: partition@38000 {
98                                 label = "factory";
99                                 reg = <0x38000 0x8000>;
100                                 read-only;
101                         };
102
103                         partition@40000 {
104                                 label = "defaults";
105                                 reg = <0x40000 0x10000>;
106                                 read-only;
107                         };
108
109                         partition@50000 {
110                                 compatible = "seama";
111                                 label = "firmware";
112                                 reg = <0x50000 0xfb0000>;
113                         };
114                 };
115         };
116 };
117
118 &pcie {
119         status = "okay";
120 };
121
122 &pcie0 {
123         wifi0: mt76@0,0 {
124                 reg = <0x0000 0 0 0 0>;
125                 mediatek,mtd-eeprom = <&radio 0x2000>;
126                 ieee80211-freq-limit = <5000000 6000000>;
127         };
128 };
129
130 &pcie1 {
131         wifi1: mt76@0,0 {
132                 reg = <0x0000 0 0 0 0>;
133                 mediatek,mtd-eeprom = <&radio 0>;
134                 ieee80211-freq-limit = <2400000 2500000>;
135         };
136 };
137
138 &pinctrl {
139         state_default: pinctrl0 {
140                 gpio {
141                         ralink,group = "i2c", "uart2", "uart3", "rgmii2", "sdhci";
142                         ralink,function = "gpio";
143                 };
144         };
145 };