ramips: add support for XiaoYu XY-C5
[oweals/openwrt.git] / target / linux / ramips / dts / mt7621_planex_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-boot = &led_power;
14                 led-failsafe = &led_power;
15                 led-running = &led_power;
16                 led-upgrade = &led_power;
17         };
18
19         chosen {
20                 bootargs = "console=ttyS0,57600";
21         };
22
23         leds {
24                 compatible = "gpio-leds";
25
26                 led_power: power {
27                         label = "vr500:green:power";
28                         gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
29                 };
30         };
31
32         keys {
33                 compatible = "gpio-keys-polled";
34                 poll-interval = <20>;
35
36                 reset {
37                         label = "reset";
38                         gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
39                         linux,code = <KEY_RESTART>;
40                 };
41         };
42 };
43
44 &spi0 {
45         status = "okay";
46
47         m25p80@0 {
48                 compatible = "jedec,spi-nor";
49                 reg = <0>;
50                 spi-max-frequency = <10000000>;
51
52                 partitions {
53                         compatible = "fixed-partitions";
54                         #address-cells = <1>;
55                         #size-cells = <1>;
56
57                         partition@0 {
58                                 label = "u-boot";
59                                 reg = <0x0 0x30000>;
60                                 read-only;
61                         };
62
63                         partition@30000 {
64                                 label = "u-boot-env";
65                                 reg = <0x30000 0x10000>;
66                                 read-only;
67                         };
68
69                         factory: partition@40000 {
70                                 label = "factory";
71                                 reg = <0x40000 0x10000>;
72                                 read-only;
73                         };
74
75                         partition@50000 {
76                                 compatible = "denx,uimage";
77                                 label = "firmware";
78                                 reg = <0x50000 0x3fb0000>;
79                         };
80                 };
81         };
82 };
83
84 &ethernet {
85         mtd-mac-address = <&factory 0xe000>;
86 };
87
88 &pinctrl {
89         state_default: pinctrl0 {
90                 gpio {
91                         ralink,group = "i2c", "uart2", "uart3", "rgmii2", "sdhci";
92                         ralink,function = "gpio";
93                 };
94         };
95 };