da9167ad8199246dbf62d7a5caa1f815953f48f2
[openwrt/openwrt.git] / target / linux / ramips / dts / RB750Gr3.dts
1 /dts-v1/;
2
3 #include "mt7621.dtsi"
4
5 #include <dt-bindings/input/input.h>
6 #include <dt-bindings/gpio/gpio.h>
7
8 / {
9 compatible = "mikrotik,rb750gr3", "mediatek,mt7621-soc";
10 model = "MikroTik RB750Gr3";
11
12 aliases {
13 led-boot = &led_pwr;
14 led-failsafe = &led_pwr;
15 led-running = &led_pwr;
16 led-upgrade = &led_pwr;
17 };
18
19 memory@0 {
20 device_type = "memory";
21 reg = <0x0 0x10000000>;
22 };
23
24 chosen {
25 bootargs = "console=ttyS0,115200";
26 };
27
28 gpio-leds {
29 compatible = "gpio-leds";
30
31 led_pwr: pwr {
32 label = "rb750gr3:blue:pwr";
33 gpios = <&gpio0 16 GPIO_ACTIVE_HIGH>;
34 };
35
36 usr {
37 label = "rb750gr3:green:usr";
38 gpios = <&gpio0 0 GPIO_ACTIVE_HIGH>;
39 };
40 };
41
42 gpio-keys-polled {
43 compatible = "gpio-keys-polled";
44 poll-interval = <20>;
45
46 mode {
47 label = "mode";
48 gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
49 linux,code = <KEY_RFKILL>;
50 };
51
52 res {
53 label = "res";
54 gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
55 linux,code = <KEY_RESTART>;
56 };
57 };
58
59 gpio_export {
60 compatible = "gpio-export";
61 #size-cells = <0>;
62
63 buzzer {
64 gpio-export,name = "buzzer";
65 gpio-export,output = <0>;
66 gpios = <&gpio0 15 GPIO_ACTIVE_HIGH>;
67 };
68
69 usb {
70 gpio-export,name = "usb";
71 gpio-export,output = <1>;
72 gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
73 };
74 };
75 };
76
77 &spi0 {
78 status = "okay";
79
80 m25p80@0 {
81 compatible = "jedec,spi-nor";
82 reg = <0>;
83 spi-max-frequency = <10000000>;
84 m25p,chunked-io = <32>;
85
86 partitions {
87 compatible = "fixed-partitions";
88 #address-cells = <1>;
89 #size-cells = <1>;
90
91 partition@0 {
92 label = "RouterBoot";
93 reg = <0x0 0x40000>;
94 read-only;
95 compatible = "fixed-partitions";
96 #address-cells = <1>;
97 #size-cells = <1>;
98
99 partition@0 {
100 label = "bootloader1";
101 reg = <0x0 0xf000>;
102 read-only;
103 };
104
105 hard_config: partition@f000 {
106 label = "hard_config";
107 reg = <0xf000 0x1000>;
108 read-only;
109 };
110
111 partition@10000 {
112 label = "bootloader2";
113 reg = <0x10000 0xf000>;
114 read-only;
115 };
116
117 partition@20000 {
118 label = "soft_config";
119 reg = <0x20000 0x1000>;
120 };
121
122 partition@30000 {
123 label = "bios";
124 reg = <0x30000 0x1000>;
125 read-only;
126 };
127 };
128
129 partition@40000 {
130 compatible = "mikrotik,minor";
131 label = "firmware";
132 reg = <0x040000 0xfc0000>;
133 };
134 };
135 };
136 };
137
138 &ethernet {
139 mtd-mac-address = <&hard_config 0x0010>;
140 mtd-mac-address-increment = <1>;
141 };
142
143 &pinctrl {
144 state_default: pinctrl0 {
145 gpio {
146 ralink,group = "i2c", "uart2", "uart3", "pcie", "rgmii2", "jtag";
147 ralink,function = "gpio";
148 };
149 };
150 };
151
152 &sdhci {
153 status = "okay";
154 };