bcm63xx: ar-5315u: expose LEDs through controller
[openwrt/staging/luka.git] / target / linux / bcm63xx / dts / bcm6318-comtrend-ar-5315u.dts
1 /dts-v1/;
2
3 #include "bcm6318.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 model = "Comtrend AR-5315u";
9 compatible = "comtrend,ar-5315u", "brcm,bcm6318";
10
11 aliases {
12 led-boot = &led_power_green;
13 led-failsafe = &led_power_green;
14 led-running = &led_power_green;
15 led-upgrade = &led_power_green;
16 };
17
18 chosen {
19 bootargs = "rootfstype=squashfs,jffs2 noinitrd console=ttyS0,115200";
20 stdout-path = "serial0:115200n8";
21 };
22
23 keys {
24 compatible = "gpio-keys-polled";
25 #address-cells = <1>;
26 #size-cells = <0>;
27 poll-interval = <20>;
28
29 wps {
30 label = "wps";
31 gpios = <&pinctrl 3 1>;
32 linux,code = <KEY_WPS_BUTTON>;
33 debounce-interval = <60>;
34 };
35
36 reset {
37 label = "reset";
38 gpios = <&pinctrl 33 1>;
39 linux,code = <KEY_RESTART>;
40 debounce-interval = <60>;
41 };
42 };
43 };
44
45 &hsspi {
46 status = "okay";
47
48 flash@0 {
49 compatible = "jedec,spi-nor";
50 spi-max-frequency = <62500000>;
51 spi-tx-bus-width = <2>;
52 spi-rx-bus-width = <2>;
53 reg = <0>;
54
55 #address-cells = <1>;
56 #size-cells = <1>;
57
58 partitions {
59 compatible = "fixed-partitions";
60 #address-cells = <1>;
61 #size-cells = <1>;
62
63 cfe@0 {
64 reg = <0x000000 0x010000>;
65 label = "cfe";
66 read-only;
67 };
68
69 linux@10000 {
70 reg = <0x010000 0xfe0000>;
71 label = "linux";
72 compatible = "brcm,bcm963xx-imagetag";
73 };
74
75 nvram@ff0000 {
76 reg = <0xff0000 0x010000>;
77 label = "nvram";
78 };
79 };
80 };
81 };
82
83 &leds {
84 status = "okay";
85
86 pinctrl-names = "default";
87 pinctrl-0 = <&pinctrl_leds
88 &pinctrl_ephy0_act_led &pinctrl_ephy1_act_led
89 &pinctrl_ephy2_act_led &pinctrl_ephy3_act_led>;
90
91 led@0 {
92 reg = <0>;
93 active-low;
94 label = "AR-5315u:green:wps";
95 };
96
97 led_power_green: led@1 {
98 reg = <1>;
99 active-low;
100 label = "AR-5315u:green:power";
101 default-state = "on";
102 };
103
104 led@2 {
105 reg = <2>;
106 active-low;
107 label = "AR-5315u:green:usb";
108 };
109
110 led@4 {
111 reg = <4>;
112 brcm,hardware-controlled;
113 brcm,link-signal-sources = <4>;
114 /* EPHY0 Act */
115 };
116
117 led@5 {
118 reg = <5>;
119 brcm,hardware-controlled;
120 brcm,link-signal-sources = <5>;
121 /* EPHY1 Act */
122 };
123
124 led@6 {
125 reg = <6>;
126 brcm,hardware-controlled;
127 brcm,link-signal-sources = <6>;
128 /* EPHY2 Act */
129 };
130
131 led@7 {
132 reg = <7>;
133 brcm,hardware-controlled;
134 brcm,link-signal-sources = <7>;
135 /* EPHY3 Act */
136 };
137
138 led@8 {
139 reg = <8>;
140 active-low;
141 label = "AR-5315u:green:inet";
142 };
143
144 led@9 {
145 reg = <9>;
146 active-low;
147 label = "AR-5315u:red:inet";
148 };
149
150 led@10 {
151 reg = <10>;
152 active-low;
153 label = "AR-5315u:green:dsl";
154 };
155
156 led@11 {
157 reg = <11>;
158 active-low;
159 label = "AR-5315u:red:power";
160 };
161 };
162
163 &pinctrl {
164 pinctrl_leds: leds {
165 function = "led";
166 pins = "gpio0", "gpio1",
167 "gpio2", "gpio8",
168 "gpio9", "gpio10",
169 "gpio11";
170 };
171 };
172
173 &uart0 {
174 status = "okay";
175 };