9e8b86ed7cc1518318d5bde03e937c38c21f9302
[openwrt/openwrt.git] / target / linux / ramips / dts / DIR-615-H1.dts
1 /dts-v1/;
2
3 #include "rt3352.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "dlink,dir-615-h1", "ralink,rt3352-soc";
10 model = "D-Link DIR-615 H1";
11
12 gpio-leds {
13 compatible = "gpio-leds";
14
15 status {
16 label = "dir-615-h1:amber:status";
17 gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
18 };
19
20 status2 {
21 label = "dir-615-h1:green:status";
22 gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
23 };
24
25 wan {
26 label = "dir-615-h1:amber:wan";
27 gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
28 };
29
30 wan2 {
31 label = "dir-615-h1:green:wan";
32 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
33 };
34
35 wps {
36 label = "dir-615-h1:blue:wps";
37 gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
38 };
39 };
40
41 gpio-keys-polled {
42 compatible = "gpio-keys-polled";
43 #address-cells = <1>;
44 #size-cells = <0>;
45 poll-interval = <20>;
46
47 reset {
48 label = "reset";
49 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
50 linux,code = <KEY_RESTART>;
51 };
52
53 wps {
54 label = "wps";
55 gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
56 linux,code = <KEY_WPS_BUTTON>;
57 };
58 };
59 };
60
61 &spi0 {
62 status = "okay";
63
64 m25p80@0 {
65 #address-cells = <1>;
66 #size-cells = <1>;
67 compatible = "jedec,spi-nor";
68 reg = <0>;
69 spi-max-frequency = <10000000>;
70
71 partition@0 {
72 label = "u-boot";
73 reg = <0x0 0x30000>;
74 read-only;
75 };
76
77 partition@30000 {
78 label = "u-boot-env";
79 reg = <0x30000 0x10000>;
80 read-only;
81 };
82
83 factory: partition@40000 {
84 label = "factory";
85 reg = <0x40000 0x10000>;
86 read-only;
87 };
88
89 partition@50000 {
90 label = "firmware";
91 reg = <0x50000 0x3b0000>;
92 };
93 };
94 };
95
96 &pinctrl {
97 state_default: pinctrl0 {
98 gpio {
99 ralink,group = "i2c", "jtag", "uartf";
100 ralink,function = "gpio";
101 };
102
103 rgmii {
104 ralink,group = "rgmii";
105 ralink,function = "rgmii";
106 };
107
108 mdio {
109 ralink,group = "mdio";
110 ralink,function = "mdio";
111 };
112 };
113 };
114
115 &ethernet {
116 mtd-mac-address = <&factory 0x28>;
117 };
118
119 &esw {
120 mediatek,portmap = <0x2f>;
121 };
122
123 &wmac {
124 ralink,mtd-eeprom = <&factory 0>;
125 };