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