ramips: move dts-v1 statement to top-level DTSI files
[openwrt/openwrt.git] / target / linux / ramips / dts / rt3052_upvel_ur-336un.dts
1 #include "rt3050.dtsi"
2
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5
6 / {
7 compatible = "upvel,ur-336un", "ralink,rt3052-soc";
8 model = "UPVEL UR-336UN";
9
10 aliases {
11 led-boot = &led_wps;
12 led-failsafe = &led_wps;
13 led-running = &led_wps;
14 led-upgrade = &led_wps;
15 };
16
17 flash@1f000000 {
18 compatible = "cfi-flash";
19 reg = <0x1f000000 0x800000>;
20 bank-width = <2>;
21 device-width = <2>;
22
23 partitions {
24 compatible = "fixed-partitions";
25 #address-cells = <1>;
26 #size-cells = <1>;
27
28 partition@0 {
29 label = "u-boot";
30 reg = <0x0 0x30000>;
31 read-only;
32 };
33
34 partition@30000 {
35 label = "u-boot-env";
36 reg = <0x30000 0x10000>;
37 read-only;
38 };
39
40 factory: partition@40000 {
41 label = "factory";
42 reg = <0x40000 0x10000>;
43 read-only;
44 };
45
46 partition@50000 {
47 compatible = "denx,uimage";
48 label = "firmware";
49 reg = <0x50000 0x7b0000>;
50 };
51 };
52 };
53
54 leds {
55 compatible = "gpio-leds";
56
57 3g {
58 label = "ur-336un:green:3g";
59 gpios = <&gpio0 9 GPIO_ACTIVE_LOW>;
60 };
61
62 gateway {
63 label = "ur-336un:green:gateway";
64 gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
65 };
66
67 ap {
68 label = "ur-336un:green:ap";
69 gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
70 };
71
72 led_wps: wps {
73 label = "ur-336un:green:wps";
74 gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
75 };
76
77 station {
78 label = "ur-336un:green:station";
79 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
80 };
81 };
82
83 keys {
84 compatible = "gpio-keys-polled";
85 poll-interval = <20>;
86
87 reset_wps {
88 label = "reset_wps";
89 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
90 linux,code = <KEY_RESTART>;
91 };
92
93 mode {
94 label = "mode";
95 gpios = <&gpio0 7 GPIO_ACTIVE_LOW>;
96 linux,code = <BTN_0>;
97 };
98 };
99 };
100
101 &state_default {
102 gpio {
103 groups = "spi", "i2c", "jtag", "rgmii", "mdio", "uartf";
104 function = "gpio";
105 };
106 };
107
108 &ethernet {
109 mtd-mac-address = <&factory 0x4004>;
110 };
111
112 &esw {
113 mediatek,portmap = <0x2f>;
114 };
115
116 &wmac {
117 ralink,mtd-eeprom = <&factory 0x0>;
118 };
119
120 &otg {
121 status = "okay";
122 };