ramips: Use dts alias based status led
[openwrt/openwrt.git] / target / linux / ramips / dts / VR500.dts
1 /dts-v1/;
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "planex,vr500", "mediatek,mt7621-soc";
10 model = "Planex VR500";
11
12 aliases {
13 led-status = &led_power;
14 };
15
16 memory@0 {
17 device_type = "memory";
18 reg = <0x0 0x10000000>;
19 };
20
21 chosen {
22 bootargs = "console=ttyS0,57600";
23 };
24
25 gpio-leds {
26 compatible = "gpio-leds";
27
28 led_power: power {
29 label = "vr500:green:power";
30 gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
31 };
32 };
33
34 gpio-keys-polled {
35 compatible = "gpio-keys-polled";
36 #address-cells = <1>;
37 #size-cells = <0>;
38 poll-interval = <20>;
39
40 reset {
41 label = "reset";
42 gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
43 linux,code = <KEY_RESTART>;
44 };
45 };
46 };
47
48 &spi0 {
49 status = "okay";
50
51 m25p80@0 {
52 #address-cells = <1>;
53 #size-cells = <1>;
54 compatible = "jedec,spi-nor";
55 reg = <0>;
56 spi-max-frequency = <10000000>;
57 m25p,chunked-io = <32>;
58
59 partition@0 {
60 label = "u-boot";
61 reg = <0x0 0x30000>;
62 read-only;
63 };
64
65 partition@30000 {
66 label = "u-boot-env";
67 reg = <0x30000 0x10000>;
68 read-only;
69 };
70
71 factory: partition@40000 {
72 label = "factory";
73 reg = <0x40000 0x10000>;
74 read-only;
75 };
76
77 partition@50000 {
78 label = "firmware";
79 reg = <0x50000 0x3fb0000>;
80 };
81 };
82 };
83
84 &pinctrl {
85 state_default: pinctrl0 {
86 gpio {
87 ralink,group = "i2c", "uart2", "uart3", "rgmii2", "sdhci";
88 ralink,function = "gpio";
89 };
90 };
91 };