ramips: move partitions into partition table node
[openwrt/openwrt.git] / target / linux / ramips / dts / Timecloud.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 = "thunder,timecloud", "mediatek,mt7621-soc";
10 model = "Thunder Timecloud";
11
12 aliases {
13 led-status = &led_statuso;
14 };
15
16 memory@0 {
17 device_type = "memory";
18 reg = <0x0 0x10000000>;
19 };
20
21 chosen {
22 bootargs = "console=ttyS0,115200";
23 };
24
25 gpio-leds {
26 compatible = "gpio-leds";
27
28 statw {
29 label = "timecloud:white:status";
30 gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
31 };
32
33 led_statuso: stato {
34 label = "timecloud:orange:status";
35 gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
36 };
37
38 };
39
40 gpio-keys-polled {
41 compatible = "gpio-keys-polled";
42 poll-interval = <20>;
43
44 reset {
45 label = "reset";
46 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
47 linux,code = <KEY_RESTART>;
48 };
49
50 BTN_0 {
51 label = "BTN_0";
52 gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
53 linux,code = <BTN_0>;
54 };
55 };
56 };
57
58 &sdhci {
59 status = "okay";
60
61 pinctrl-names = "default";
62 pinctrl-0 = <&sdhci_pins>;
63 };
64
65 &spi0 {
66 status = "okay";
67
68 m25p80@0 {
69 compatible = "jedec,spi-nor";
70 reg = <0>;
71 spi-max-frequency = <10000000>;
72 m25p,chunked-io = <32>;
73
74 partitions {
75 compatible = "fixed-partitions";
76 #address-cells = <1>;
77 #size-cells = <1>;
78
79 partition@0 {
80 label = "u-boot";
81 reg = <0x0 0x30000>;
82 read-only;
83 };
84
85 partition@30000 {
86 label = "u-boot-env";
87 reg = <0x30000 0x10000>;
88 read-only;
89 };
90
91 factory: partition@40000 {
92 label = "factory";
93 reg = <0x40000 0x10000>;
94 read-only;
95 };
96
97 partition@50000 {
98 label = "firmware";
99 reg = <0x50000 0xfb0000>;
100 };
101 };
102 };
103 };
104
105 &ethernet {
106 mtd-mac-address = <&factory 0xe000>;
107 };
108
109 &pinctrl {
110 state_default: pinctrl0 {
111 gpio {
112 ralink,group = "i2c", "uart2", "jtag";
113 ralink,function = "gpio";
114 };
115 };
116 };