ramips: cleanup SPI flash device tree properties usage
[openwrt/openwrt.git] / target / linux / ramips / dts / M3.dts
1 /dts-v1/;
2
3 #include "rt5350.dtsi"
4
5 #include <dt-bindings/input/input.h>
6
7 / {
8 compatible = "M3", "ralink,rt5350-soc";
9 model = "Poray M3";
10
11 gpio-leds {
12 compatible = "gpio-leds";
13
14 status {
15 label = "m3:blue:status";
16 gpios = <&gpio0 9 1>;
17 };
18 };
19
20 gpio-keys-polled {
21 compatible = "gpio-keys-polled";
22 #address-cells = <1>;
23 #size-cells = <0>;
24 poll-interval = <20>;
25
26 reset {
27 label = "reset";
28 gpios = <&gpio0 10 1>;
29 linux,code = <KEY_RESTART>;
30 };
31
32 mode {
33 label = "mode";
34 gpios = <&gpio0 17 1>;
35 linux,code = <BTN_0>;
36 linux,input-type = <EV_SW>;
37 };
38 };
39 };
40
41 &spi0 {
42 status = "okay";
43
44 m25p80@0 {
45 #address-cells = <1>;
46 #size-cells = <1>;
47 compatible = "jedec,spi-nor";
48 reg = <0>;
49 spi-max-frequency = <10000000>;
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 label = "factory";
65 reg = <0x40000 0x10000>;
66 read-only;
67 };
68
69 partition@50000 {
70 label = "firmware";
71 reg = <0x50000 0x3b0000>;
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 };