ramips: Use dts alias based status led
[openwrt/staging/wigyori.git] / target / linux / ramips / dts / ATP-52B.dts
1 /dts-v1/;
2
3 #include "rt3050.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "argus,atp-52b", "ralink,rt3052-soc";
10 model = "Argus ATP-52B";
11
12 aliases {
13 led-status = &led_run;
14 };
15
16 cfi@1f000000 {
17 compatible = "cfi-flash";
18 reg = <0x1f000000 0x800000>;
19 bank-width = <2>;
20 device-width = <2>;
21 #address-cells = <1>;
22 #size-cells = <1>;
23
24 partition@0 {
25 label = "bootloader";
26 reg = <0x0 0x30000>;
27 read-only;
28 };
29
30 partition@30000 {
31 label = "config";
32 reg = <0x30000 0x10000>;
33 };
34
35 factory: partition@40000 {
36 label = "factory";
37 reg = <0x40000 0x10000>;
38 };
39
40 partition@50000 {
41 label = "firmware";
42 reg = <0x50000 0x7a0000>;
43 };
44 };
45
46 gpio-leds {
47 compatible = "gpio-leds";
48
49 led_run: run {
50 label = "atp-52b:green:run";
51 gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
52 };
53
54 net {
55 label = "atp-52b:amber:net";
56 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
57 };
58 };
59
60 gpio-keys-polled {
61 compatible = "gpio-keys-polled";
62 #address-cells = <1>;
63 #size-cells = <0>;
64 poll-interval = <20>;
65
66 wps {
67 label = "wps";
68 gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
69 linux,code = <KEY_WPS_BUTTON>;
70 };
71
72 reset {
73 label = "reset";
74 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
75 linux,code = <KEY_RESTART>;
76 };
77 };
78 };
79
80 &pinctrl {
81 state_default: pinctrl0 {
82 gpio {
83 ralink,group = "i2c", "jtag", "rgmii", "mdio", "uartf";
84 ralink,function = "gpio";
85 };
86 };
87 };
88
89
90 &ethernet {
91 mtd-mac-address = <&factory 0x4>;
92 };
93
94 &esw {
95 mediatek,portmap = <0x3e>;
96 };
97
98 &wmac {
99 ralink,mtd-eeprom = <&factory 0>;
100 };
101
102 &otg {
103 status = "okay";
104 };