ramips: add support for indicating the boot state using multiple leds
[openwrt/staging/wigyori.git] / target / linux / ramips / dts / HC5661A.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 = "hiwifi,hc5661a", "mediatek,mt7628an-soc";
10 model = "HiWiFi HC5661A";
11
12 aliases {
13 led-boot = &led_system;
14 led-failsafe = &led_system;
15 led-running = &led_system;
16 led-upgrade = &led_system;
17 };
18
19 chosen {
20 bootargs = "console=ttyS0,115200";
21 };
22
23 memory@0 {
24 device_type = "memory";
25 reg = <0x0 0x8000000>;
26 };
27
28 gpio-leds {
29 compatible = "gpio-leds";
30
31 led_system: system {
32 label = "hc5661a:blue:system";
33 gpios = <&gpio1 5 GPIO_ACTIVE_HIGH>;
34 };
35 internet {
36 label = "hc5661a:blue:internet";
37 gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>;
38 };
39 wlan2g {
40 label = "hc5661a:blue:wlan2g";
41 gpios = <&gpio1 12 GPIO_ACTIVE_HIGH>;
42 };
43 };
44
45 gpio-keys {
46 compatible = "gpio-keys-polled";
47 poll-interval = <20>;
48
49 reset {
50 label = "reset";
51 gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
52 linux,code = <KEY_RESTART>;
53 };
54 };
55 };
56
57 &pinctrl {
58 state_default: pinctrl0 {
59 gpio {
60 ralink,group = "i2c", "refclk", "wled_an";
61 ralink,function = "gpio";
62 };
63 };
64 };
65
66 &sdhci {
67 status = "okay";
68 };
69
70 &spi0 {
71 status = "okay";
72
73 m25p80@0 {
74 compatible = "jedec,spi-nor";
75 reg = <0>;
76 linux,modalias = "m25p80", "w25q128";
77 spi-max-frequency = <10000000>;
78 m25p,chunked-io = <32>;
79
80 partitions {
81 compatible = "fixed-partitions";
82 #address-cells = <1>;
83 #size-cells = <1>;
84
85 partition@0 {
86 label = "u-boot";
87 reg = <0x0 0x30000>;
88 read-only;
89 };
90
91 partition@30000 {
92 label = "hw_panic";
93 reg = <0x30000 0x10000>;
94 read-only;
95 };
96
97 factory: partition@40000 {
98 label = "factory";
99 reg = <0x40000 0x10000>;
100 read-only;
101 };
102
103 partition@50000 {
104 label = "firmware";
105 reg = <0x50000 0xf70000>;
106 };
107
108 partition@fc0000 {
109 label = "oem";
110 reg = <0xfc0000 0x20000>;
111 read-only;
112 };
113
114 bdinfo: partition@fe0000 {
115 label = "bdinfo";
116 reg = <0xfe0000 0x10000>;
117 read-only;
118 };
119
120 partition@ff0000 {
121 label = "backup";
122 reg = <0xff0000 0x10000>;
123 read-only;
124 };
125 };
126 };
127 };
128
129 &ethernet {
130 mtd-mac-address = <&factory 0x4>;
131 mediatek,portmap = "wllll";
132 };
133
134 &wmac {
135 status = "okay";
136 };