ramips: add proper system clock and reset driver support for mt7621
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7621_mikrotik_routerboard-m33g.dts
1 #include "mt7621_mikrotik.dtsi"
2
3 / {
4 compatible = "mikrotik,routerboard-m33g", "mediatek,mt7621-soc";
5 model = "MikroTik RouterBOARD M33G";
6
7 aliases {
8 led-boot = &led_usr;
9 led-failsafe = &led_usr;
10 led-running = &led_usr;
11 led-upgrade = &led_usr;
12 };
13
14 leds {
15 compatible = "gpio-leds";
16
17 led_usr: usr {
18 label = "green:usr";
19 gpios = <&gpio 0 GPIO_ACTIVE_HIGH>;
20 };
21 };
22
23 pcie0_vcc_reg {
24 compatible = "regulator-fixed";
25 regulator-name = "pcie0_vcc";
26
27 regulator-min-microvolt = <3300000>;
28 regulator-max-microvolt = <3300000>;
29 gpio = <&gpio 9 GPIO_ACTIVE_HIGH>;
30 enable-active-high;
31 regulator-boot-on;
32 regulator-always-on;
33 };
34
35 pcie1_vcc_reg {
36 compatible = "regulator-fixed";
37 regulator-name = "pcie1_vcc";
38
39 regulator-min-microvolt = <3300000>;
40 regulator-max-microvolt = <3300000>;
41 gpio = <&gpio 10 GPIO_ACTIVE_HIGH>;
42 enable-active-high;
43 regulator-boot-on;
44 regulator-always-on;
45 };
46
47 pcie2_vcc_reg {
48 compatible = "regulator-fixed";
49 regulator-name = "pcie2_vcc";
50
51 regulator-min-microvolt = <3300000>;
52 regulator-max-microvolt = <3300000>;
53 gpio = <&gpio 11 GPIO_ACTIVE_HIGH>;
54 enable-active-high;
55 regulator-boot-on;
56 regulator-always-on;
57 };
58
59 usb_vcc_reg {
60 compatible = "regulator-fixed";
61 regulator-name = "usb_vcc";
62
63 regulator-min-microvolt = <5000000>;
64 regulator-max-microvolt = <5000000>;
65 gpio = <&gpio 12 GPIO_ACTIVE_HIGH>;
66 enable-active-high;
67 regulator-always-on;
68 };
69 };
70
71 &spi0 {
72 flash@1 {
73 compatible = "jedec,spi-nor";
74 reg = <1>;
75 spi-max-frequency = <33000000>;
76
77 partitions {
78 compatible = "fixed-partitions";
79 #address-cells = <1>;
80 #size-cells = <1>;
81
82 // Region <0x0 0x40000> seems reserved by OEM
83
84 partition@40000 {
85 compatible = "mikrotik,minor";
86 label = "firmware";
87 reg = <0x040000 0xfc0000>;
88 };
89 };
90 };
91 };
92
93 &gmac1 {
94 status = "okay";
95 label = "wan";
96 phy-handle = <&ethphy0>;
97 };
98
99 &mdio {
100 ethphy0: ethernet-phy@0 {
101 reg = <0>;
102 };
103 };
104
105 &switch0 {
106 ports {
107 port@1 {
108 status = "okay";
109 label = "lan1";
110 };
111
112 port@2 {
113 status = "okay";
114 label = "lan2";
115 };
116 };
117 };
118
119 &state_default {
120 gpio {
121 groups = "uart2", "wdt";
122 function = "gpio";
123 };
124 };
125
126 &sdhci {
127 status = "okay";
128 };
129
130 &i2c {
131 status = "okay";
132 };
133
134 &pcie {
135 status = "okay";
136 };
137
138 &uartlite3 {
139 status = "okay";
140 };