|
3 | 3 | * Copyright (C) 2025 MediaTek Inc. |
4 | 4 | * Author: Sam.Shih <sam.shih@mediatek.com> |
5 | 5 | */ |
| 6 | + |
6 | 7 | /dts-v1/; |
| 8 | + |
7 | 9 | #include "mt7987a.dtsi" |
8 | 10 | #include <dt-bindings/input/input.h> |
9 | 11 | #include <dt-bindings/leds/common.h> |
10 | 12 | #include "mt7987a-bananapi-bpi-r4-lite-mikrobus.dtsi" |
| 13 | + |
11 | 14 | / { |
12 | 15 | model = "Bananapi BPI-R4-LITE"; |
13 | 16 | compatible = "bananapi,bpi-r4-lite", |
14 | 17 | "mediatek,mt7987a", "mediatek,mt7987"; |
| 18 | + |
15 | 19 | aliases { |
16 | 20 | /* mt7987 I2C0 */ |
17 | 21 | i2c0 = &i2c0; |
|
21 | 25 | i2c3 = &imux2_MikroBus; |
22 | 26 | i2c4 = &imux3; |
23 | 27 | }; |
| 28 | + |
24 | 29 | chosen { |
25 | 30 | bootargs = "console=ttyS0,115200n1 loglevel=6 \ |
26 | 31 | earlycon=uart8250,mmio32,0x11000000 \ |
27 | 32 | pci=pcie_bus_perf ubi.block=0,firmware \ |
28 | 33 | root=/dev/fit0 rootwait"; |
29 | 34 | }; |
| 35 | + |
30 | 36 | gpio-keys { |
31 | 37 | compatible = "gpio-keys"; |
32 | 38 | reset { |
|
42 | 48 | debounce-interval = <10>; |
43 | 49 | }; |
44 | 50 | }; |
| 51 | + |
45 | 52 | pwm-leds { |
46 | 53 | compatible = "pwm-leds"; |
47 | 54 | status = "okay"; |
|
83 | 90 | maximum-power-milliwatt = <3000>; |
84 | 91 | }; |
85 | 92 | }; |
| 93 | + |
86 | 94 | &fan { |
87 | 95 | pwms = <&pwm 2 50000>; |
88 | 96 | status = "okay"; |
89 | 97 | }; |
| 98 | + |
90 | 99 | &gmac0 { |
91 | 100 | phy-mode = "2500base-x"; |
92 | 101 | status = "okay"; |
|
96 | 105 | pause; |
97 | 106 | }; |
98 | 107 | }; |
| 108 | + |
99 | 109 | &gmac1 { |
100 | 110 | phy-mode = "internal"; |
101 | 111 | phy-handle = <&phy15>; |
102 | 112 | status = "okay"; |
103 | 113 | }; |
| 114 | + |
104 | 115 | &hnat { |
105 | 116 | mtketh-lan2 = "eth2"; |
106 | 117 | mtketh-max-gmac = <3>; |
107 | 118 | }; |
| 119 | + |
108 | 120 | &pwm { |
109 | 121 | pinctrl-names = "default"; |
110 | 122 | pinctrl-0 = <&pwm_pins>; |
111 | 123 | status = "okay"; |
112 | 124 | }; |
| 125 | + |
113 | 126 | &pwm_pins { |
114 | 127 | mux { |
115 | 128 | /* |
|
121 | 134 | groups = "pwm0", "pwm1_0", "pwm2_0"; |
122 | 135 | }; |
123 | 136 | }; |
| 137 | + |
124 | 138 | &i2c0 { |
125 | 139 | pinctrl-names = "default"; |
126 | 140 | pinctrl-0 = <&i2c0_pins>; |
|
130 | 144 | reg = <0x70>; |
131 | 145 | #address-cells = <1>; |
132 | 146 | #size-cells = <0>; |
| 147 | + |
133 | 148 | imux0_rtc: i2c@0 { |
134 | 149 | #address-cells = <1>; |
135 | 150 | #size-cells = <0>; |
136 | 151 | reg = <0x0>; |
| 152 | + |
137 | 153 | rtc@51 { |
138 | 154 | compatible = "nxp,pcf8563"; |
139 | 155 | reg = <0x51>; |
140 | 156 | }; |
| 157 | + |
141 | 158 | eeprom@57 { |
142 | 159 | compatible = "atmel,24c02"; |
143 | 160 | reg = <0x57>; |
|
146 | 163 | size = <256>; |
147 | 164 | }; |
148 | 165 | }; |
| 166 | + |
149 | 167 | imux1_sfp: i2c@1 { |
150 | 168 | #address-cells = <1>; |
151 | 169 | #size-cells = <0>; |
152 | 170 | reg = <0x1>; |
153 | 171 | }; |
| 172 | + |
154 | 173 | imux2_MikroBus: i2c@2 { |
155 | 174 | #address-cells = <1>; |
156 | 175 | #size-cells = <0>; |
157 | 176 | reg = <0x2>; |
158 | 177 | }; |
| 178 | + |
159 | 179 | imux3: i2c@3 { |
160 | 180 | #address-cells = <1>; |
161 | 181 | #size-cells = <0>; |
162 | 182 | reg = <0x3>; |
| 183 | + |
163 | 184 | pca9555: i2c-gpio-expander@20 { |
164 | 185 | compatible = "nxp,pca9555"; |
165 | 186 | gpio-controller; |
166 | 187 | #gpio-cells = <2>; |
167 | 188 | reg = <0x20>; |
168 | 189 | }; |
| 190 | + |
169 | 191 | wifi_eeprom@50 { |
170 | 192 | compatible = "atmel,24c02"; |
171 | 193 | reg = <0x50>; |
|
176 | 198 | }; |
177 | 199 | }; |
178 | 200 | }; |
| 201 | + |
179 | 202 | &mdio { |
180 | 203 | /* built-in 2.5G Ethernet PHY */ |
181 | 204 | phy15: phy@15 { |
|
186 | 209 | phy-mode = "internal"; |
187 | 210 | active-low; |
188 | 211 | }; |
| 212 | + |
189 | 213 | switch31: switch@31 { |
190 | 214 | compatible = "mediatek,mt7531"; |
191 | 215 | reg = <31>; |
|
208 | 232 | phys = <&tphyu2port0 PHY_TYPE_USB2>, |
209 | 233 | <&tphyu3port0 PHY_TYPE_USB3>; |
210 | 234 | }; |
| 235 | + |
211 | 236 | &switch31 { |
212 | 237 | ports { |
213 | 238 | #address-cells = <1>; |
214 | 239 | #size-cells = <0>; |
| 240 | + |
215 | 241 | port@0 { |
216 | 242 | reg = <0>; |
217 | 243 | label = "lan0"; |
218 | 244 | }; |
| 245 | + |
219 | 246 | port@1 { |
220 | 247 | reg = <1>; |
221 | 248 | label = "lan1"; |
222 | 249 | }; |
| 250 | + |
223 | 251 | port@2 { |
224 | 252 | reg = <2>; |
225 | 253 | label = "lan2"; |
226 | 254 | }; |
| 255 | + |
227 | 256 | port@3 { |
228 | 257 | reg = <3>; |
229 | 258 | label = "lan3"; |
230 | 259 | }; |
| 260 | + |
231 | 261 | port@5 { |
232 | 262 | reg = <5>; |
233 | 263 | label = "sfp0"; |
234 | 264 | phy-mode = "2500base-x"; |
235 | 265 | sfp = <&sfp>; |
236 | 266 | managed = "in-band-status"; |
237 | 267 | }; |
| 268 | + |
238 | 269 | port@6 { |
239 | 270 | reg = <6>; |
240 | 271 | label = "cpu"; |
|
248 | 279 | }; |
249 | 280 | }; |
250 | 281 | }; |
| 282 | + |
251 | 283 | &tphyu3port0 { |
252 | 284 | status = "okay"; |
253 | 285 | }; |
0 commit comments