d728449a481f178c18b09f576b0c6a38c684ea1e
[openwrt/openwrt.git] / target / linux / ramips / dts / DIR-810L.dts
1 /dts-v1/;
2
3 #include "mt7620a.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "dlink,dir-810l", "ralink,mt7620a-soc";
10 model = "D-Link DIR-810L";
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 };
18
19 keys {
20 compatible = "gpio-keys-polled";
21 poll-interval = <20>;
22
23 reset {
24 label = "reset";
25 gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
26 linux,code = <BTN_0>;
27 };
28
29 wps {
30 label = "wps";
31 gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
32 linux,code = <BTN_0>;
33 };
34 };
35
36 leds {
37 compatible = "gpio-leds";
38
39 led_power_green: power {
40 label = "dir-810l:green:power";
41 gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
42 };
43
44 wan {
45 label = "dir-810l:orange:wan";
46 gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
47 };
48
49 power2 {
50 label = "dir-810l:orange:power";
51 gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
52 };
53 };
54 };
55
56 &spi0 {
57 status = "okay";
58
59 m25p80@0 {
60 compatible = "jedec,spi-nor";
61 reg = <0>;
62 spi-max-frequency = <10000000>;
63
64 partitions {
65 compatible = "fixed-partitions";
66 #address-cells = <1>;
67 #size-cells = <1>;
68
69 partition@0 {
70 label = "u-boot";
71 reg = <0x0 0x30000>;
72 read-only;
73 };
74
75 partition@30000 {
76 label = "u-boot-env";
77 reg = <0x30000 0x10000>;
78 read-only;
79 };
80
81 factory: partition@40000 {
82 label = "factory";
83 reg = <0x40000 0x10000>;
84 read-only;
85 };
86
87 factory5g: partition@50000 {
88 label = "factory5g";
89 reg = <0x50000 0x10000>;
90 read-only;
91 };
92
93 partition@60000 {
94 label = "Wolf_Config";
95 reg = <0x60000 0x10000>;
96 read-only;
97 };
98
99 partition@70000 {
100 label = "MyDlink";
101 reg = <0x70000 0x80000>;
102 read-only;
103 };
104
105 partition@e0000 {
106 label = "Jffs2";
107 reg = <0xe0000 0x80000>;
108 read-only;
109 };
110
111 partition@170000 {
112 compatible = "denx,uimage";
113 label = "firmware";
114 reg = <0x170000 0x690000>;
115 };
116 };
117 };
118 };
119
120 &pinctrl {
121 state_default: pinctrl0 {
122 gpio {
123 ralink,group = "mdio", "rgmii1", "i2c", "wled", "uartf";
124 ralink,function = "gpio";
125 };
126 };
127 };
128
129 &ethernet {
130 mtd-mac-address = <&factory 0x28>;
131 mediatek,portmap = "llllw";
132 };
133
134 &gsw {
135 mediatek,port4 = "ephy";
136 pinctrl-names = "default";
137 pinctrl-0 = <&ephy_pins>;
138 };
139
140 &pcie {
141 status = "okay";
142 };
143
144 &wmac {
145 ralink,mtd-eeprom = <&factory 0>;
146 };
147
148 &pcie0 {
149 wifi@0,0 {
150 reg = <0x0000 0 0 0 0>;
151 mediatek,mtd-eeprom = <&factory 0x8000>;
152 ieee80211-freq-limit = <5000000 6000000>;
153 };
154 };