ramips: Use dts alias based status led
[openwrt/staging/dedeckeh.git] / target / linux / ramips / dts / DWR-116-A1.dts
1 /dts-v1/;
2
3 #include "mt7620n.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "dlink,dwr-116-a1", "ralink,mt7620n-soc";
10 model = "D-Link DWR-116 A1/A2";
11
12 aliases {
13 led-status = &led_status;
14 };
15
16 gpio-keys-polled {
17 compatible = "gpio-keys-polled";
18 #address-cells = <1>;
19 #size-cells = <0>;
20 poll-interval = <20>;
21
22 wps {
23 label = "wps";
24 gpios = <&gpio0 2 GPIO_ACTIVE_LOW>;
25 linux,code = <KEY_WPS_BUTTON>;
26 };
27
28 reset {
29 label = "reset";
30 gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
31 linux,code = <KEY_RESTART>;
32 };
33 };
34
35 gpio-leds {
36 compatible = "gpio-leds";
37
38 led_status: status {
39 label = "dwr-116-a1:green:status";
40 gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
41 };
42
43 wifi {
44 label = "dwr-116-a1:green:wifi";
45 gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
46 };
47 };
48 };
49
50 &gpio1 {
51 status = "okay";
52 };
53
54 &gpio3 {
55 status = "okay";
56 };
57
58 &spi0 {
59 status = "okay";
60
61 m25p80@0 {
62 #address-cells = <1>;
63 #size-cells = <1>;
64 compatible = "jedec,spi-nor";
65 reg = <0>;
66 spi-max-frequency = <50000000>;
67
68 partition@0 {
69 label = "jboot";
70 reg = <0x0 0x10000>;
71 read-only;
72 };
73
74 partition@10000 {
75 label = "firmware";
76 reg = <0x10000 0x7e0000>;
77 };
78
79 config: partition@7f0000 {
80 label = "config";
81 reg = <0x7f0000 0x10000>;
82 read-only;
83 };
84 };
85 };
86
87 &ehci {
88 status = "okay";
89 };
90
91 &ohci {
92 status = "okay";
93 };
94
95 &pinctrl {
96 state_default: pinctrl0 {
97 default {
98 ralink,group = "i2c", "wled";
99 ralink,function = "gpio";
100 };
101 };
102 };
103
104 &ethernet {
105 mediatek,portmap = "llllw";
106 pinctrl-names = "default";
107 pinctrl-0 = <&ephy_pins>;
108 };