14aea65c062105e20b1ef43d0cc1a92f186ece22
[openwrt/openwrt.git] / target / linux / ramips / dts / X8.dts
1 /dts-v1/;
2
3 #include "rt5350.dtsi"
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
7
8 / {
9 compatible = "poray,x8", "ralink,rt5350-soc";
10 model = "Poray X8";
11
12 aliases {
13 led-status = &led_power;
14 };
15
16 gpio-leds {
17 compatible = "gpio-leds";
18
19 led_power: power {
20 label = "x8:green:power";
21 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
22 };
23 };
24
25 gpio-keys-polled {
26 compatible = "gpio-keys-polled";
27 poll-interval = <20>;
28
29 reset {
30 label = "reset";
31 gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
32 linux,code = <KEY_RESTART>;
33 };
34 };
35 };
36
37 &spi0 {
38 status = "okay";
39
40 m25p80@0 {
41 compatible = "jedec,spi-nor";
42 reg = <0>;
43 spi-max-frequency = <10000000>;
44
45 partitions {
46 compatible = "fixed-partitions";
47 #address-cells = <1>;
48 #size-cells = <1>;
49
50 partition@0 {
51 label = "u-boot";
52 reg = <0x0 0x30000>;
53 read-only;
54 };
55
56 partition@30000 {
57 label = "u-boot-env";
58 reg = <0x30000 0x10000>;
59 read-only;
60 };
61
62 factory: partition@40000 {
63 label = "factory";
64 reg = <0x40000 0x10000>;
65 read-only;
66 };
67
68 partition@50000 {
69 label = "firmware";
70 reg = <0x50000 0x7b0000>;
71 };
72 };
73 };
74 };
75
76 &pinctrl {
77 state_default: pinctrl0 {
78 gpio {
79 ralink,group = "i2c", "jtag", "uartf";
80 ralink,function = "gpio";
81 };
82 };
83 };
84
85 &ethernet {
86 mtd-mac-address = <&factory 0x4>;
87 };
88
89 &esw {
90 mediatek,portmap = <0x2f>;
91 mediatek,led_polarity = <1>;
92 };
93
94 &wmac {
95 ralink,mtd-eeprom = <&factory 0>;
96 ralink,led-polarity = <1>;
97 };
98
99 &ehci {
100 status = "okay";
101 };
102
103 &ohci {
104 status = "okay";
105 };