1// SPDX-License-Identifier: GPL-2.0-only 2/* 3 * Copyright (c) 2015 MediaTek Inc. 4 * Author: Mars.C <mars.cheng@mediatek.com> 5 */ 6 7#include <dt-bindings/interrupt-controller/irq.h> 8#include <dt-bindings/interrupt-controller/arm-gic.h> 9#include <dt-bindings/clock/mediatek,mt6795-clk.h> 10#include <dt-bindings/pinctrl/mt6795-pinfunc.h> 11#include <dt-bindings/reset/mediatek,mt6795-resets.h> 12 13/ { 14 compatible = "mediatek,mt6795"; 15 interrupt-parent = <&sysirq>; 16 #address-cells = <2>; 17 #size-cells = <2>; 18 19 psci { 20 compatible = "arm,psci-0.2"; 21 method = "smc"; 22 }; 23 24 cpus { 25 #address-cells = <1>; 26 #size-cells = <0>; 27 28 cpu0: cpu@0 { 29 device_type = "cpu"; 30 compatible = "arm,cortex-a53"; 31 enable-method = "psci"; 32 reg = <0x000>; 33 cci-control-port = <&cci_control2>; 34 next-level-cache = <&l2_0>; 35 }; 36 37 cpu1: cpu@1 { 38 device_type = "cpu"; 39 compatible = "arm,cortex-a53"; 40 enable-method = "psci"; 41 reg = <0x001>; 42 cci-control-port = <&cci_control2>; 43 i-cache-size = <32768>; 44 i-cache-line-size = <64>; 45 i-cache-sets = <256>; 46 d-cache-size = <32768>; 47 d-cache-line-size = <64>; 48 d-cache-sets = <128>; 49 next-level-cache = <&l2_0>; 50 }; 51 52 cpu2: cpu@2 { 53 device_type = "cpu"; 54 compatible = "arm,cortex-a53"; 55 enable-method = "psci"; 56 reg = <0x002>; 57 cci-control-port = <&cci_control2>; 58 i-cache-size = <32768>; 59 i-cache-line-size = <64>; 60 i-cache-sets = <256>; 61 d-cache-size = <32768>; 62 d-cache-line-size = <64>; 63 d-cache-sets = <128>; 64 next-level-cache = <&l2_0>; 65 }; 66 67 cpu3: cpu@3 { 68 device_type = "cpu"; 69 compatible = "arm,cortex-a53"; 70 enable-method = "psci"; 71 reg = <0x003>; 72 cci-control-port = <&cci_control2>; 73 i-cache-size = <32768>; 74 i-cache-line-size = <64>; 75 i-cache-sets = <256>; 76 d-cache-size = <32768>; 77 d-cache-line-size = <64>; 78 d-cache-sets = <128>; 79 next-level-cache = <&l2_0>; 80 }; 81 82 cpu4: cpu@100 { 83 device_type = "cpu"; 84 compatible = "arm,cortex-a53"; 85 enable-method = "psci"; 86 reg = <0x100>; 87 cci-control-port = <&cci_control1>; 88 i-cache-size = <32768>; 89 i-cache-line-size = <64>; 90 i-cache-sets = <256>; 91 d-cache-size = <32768>; 92 d-cache-line-size = <64>; 93 d-cache-sets = <128>; 94 next-level-cache = <&l2_1>; 95 }; 96 97 cpu5: cpu@101 { 98 device_type = "cpu"; 99 compatible = "arm,cortex-a53"; 100 enable-method = "psci"; 101 reg = <0x101>; 102 cci-control-port = <&cci_control1>; 103 i-cache-size = <32768>; 104 i-cache-line-size = <64>; 105 i-cache-sets = <256>; 106 d-cache-size = <32768>; 107 d-cache-line-size = <64>; 108 d-cache-sets = <128>; 109 next-level-cache = <&l2_1>; 110 }; 111 112 cpu6: cpu@102 { 113 device_type = "cpu"; 114 compatible = "arm,cortex-a53"; 115 enable-method = "psci"; 116 reg = <0x102>; 117 cci-control-port = <&cci_control1>; 118 i-cache-size = <32768>; 119 i-cache-line-size = <64>; 120 i-cache-sets = <256>; 121 d-cache-size = <32768>; 122 d-cache-line-size = <64>; 123 d-cache-sets = <128>; 124 next-level-cache = <&l2_1>; 125 }; 126 127 cpu7: cpu@103 { 128 device_type = "cpu"; 129 compatible = "arm,cortex-a53"; 130 enable-method = "psci"; 131 reg = <0x103>; 132 cci-control-port = <&cci_control1>; 133 i-cache-size = <32768>; 134 i-cache-line-size = <64>; 135 i-cache-sets = <256>; 136 d-cache-size = <32768>; 137 d-cache-line-size = <64>; 138 d-cache-sets = <128>; 139 next-level-cache = <&l2_1>; 140 }; 141 142 cpu-map { 143 cluster0 { 144 core0 { 145 cpu = <&cpu0>; 146 }; 147 148 core1 { 149 cpu = <&cpu1>; 150 }; 151 152 core2 { 153 cpu = <&cpu2>; 154 }; 155 156 core3 { 157 cpu = <&cpu3>; 158 }; 159 }; 160 161 cluster1 { 162 core0 { 163 cpu = <&cpu4>; 164 }; 165 166 core1 { 167 cpu = <&cpu5>; 168 }; 169 170 core2 { 171 cpu = <&cpu6>; 172 }; 173 174 core3 { 175 cpu = <&cpu7>; 176 }; 177 }; 178 }; 179 180 l2_0: l2-cache0 { 181 compatible = "cache"; 182 cache-level = <2>; 183 cache-size = <1048576>; 184 cache-line-size = <64>; 185 cache-sets = <1024>; 186 cache-unified; 187 }; 188 189 l2_1: l2-cache1 { 190 compatible = "cache"; 191 cache-level = <2>; 192 cache-size = <1048576>; 193 cache-line-size = <64>; 194 cache-sets = <1024>; 195 cache-unified; 196 }; 197 }; 198 199 clk26m: oscillator-26m { 200 compatible = "fixed-clock"; 201 #clock-cells = <0>; 202 clock-frequency = <26000000>; 203 clock-output-names = "clk26m"; 204 }; 205 206 clk32k: oscillator-32k { 207 compatible = "fixed-clock"; 208 #clock-cells = <0>; 209 clock-frequency = <32000>; 210 clock-output-names = "clk32k"; 211 }; 212 213 system_clk: dummy13m { 214 compatible = "fixed-clock"; 215 clock-frequency = <13000000>; 216 #clock-cells = <0>; 217 }; 218 219 pmu { 220 compatible = "arm,cortex-a53-pmu"; 221 interrupts = <GIC_SPI 8 IRQ_TYPE_LEVEL_LOW>, 222 <GIC_SPI 9 IRQ_TYPE_LEVEL_LOW>, 223 <GIC_SPI 10 IRQ_TYPE_LEVEL_LOW>, 224 <GIC_SPI 11 IRQ_TYPE_LEVEL_LOW>; 225 interrupt-affinity = <&cpu0>, <&cpu1>, <&cpu2>, <&cpu3>; 226 }; 227 228 timer { 229 compatible = "arm,armv8-timer"; 230 interrupt-parent = <&gic>; 231 interrupts = <GIC_PPI 13 232 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, 233 <GIC_PPI 14 234 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, 235 <GIC_PPI 11 236 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>, 237 <GIC_PPI 10 238 (GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_LOW)>; 239 }; 240 241 soc { 242 #address-cells = <2>; 243 #size-cells = <2>; 244 compatible = "simple-bus"; 245 ranges; 246 247 topckgen: syscon@10000000 { 248 compatible = "mediatek,mt6795-topckgen", "syscon"; 249 reg = <0 0x10000000 0 0x1000>; 250 #clock-cells = <1>; 251 }; 252 253 infracfg: syscon@10001000 { 254 compatible = "mediatek,mt6795-infracfg", "syscon"; 255 reg = <0 0x10001000 0 0x1000>; 256 #clock-cells = <1>; 257 #reset-cells = <1>; 258 }; 259 260 pericfg: syscon@10003000 { 261 compatible = "mediatek,mt6795-pericfg", "syscon"; 262 reg = <0 0x10003000 0 0x1000>; 263 #clock-cells = <1>; 264 #reset-cells = <1>; 265 }; 266 267 pio: pinctrl@10005000 { 268 compatible = "mediatek,mt6795-pinctrl"; 269 reg = <0 0x10005000 0 0x1000>, <0 0x1000b000 0 0x1000>; 270 reg-names = "base", "eint"; 271 interrupts = <GIC_SPI 153 IRQ_TYPE_LEVEL_HIGH>, 272 <GIC_SPI 154 IRQ_TYPE_LEVEL_HIGH>; 273 gpio-controller; 274 #gpio-cells = <2>; 275 gpio-ranges = <&pio 0 0 196>; 276 interrupt-controller; 277 #interrupt-cells = <2>; 278 }; 279 280 watchdog: watchdog@10007000 { 281 compatible = "mediatek,mt6795-wdt"; 282 reg = <0 0x10007000 0 0x100>; 283 interrupts = <GIC_SPI 128 IRQ_TYPE_LEVEL_LOW>; 284 #reset-cells = <1>; 285 timeout-sec = <20>; 286 }; 287 288 timer: timer@10008000 { 289 compatible = "mediatek,mt6795-timer", 290 "mediatek,mt6577-timer"; 291 reg = <0 0x10008000 0 0x1000>; 292 interrupts = <GIC_SPI 152 IRQ_TYPE_LEVEL_LOW>; 293 clocks = <&system_clk>, <&clk32k>; 294 }; 295 296 sysirq: intpol-controller@10200620 { 297 compatible = "mediatek,mt6795-sysirq", 298 "mediatek,mt6577-sysirq"; 299 interrupt-controller; 300 #interrupt-cells = <3>; 301 interrupt-parent = <&gic>; 302 reg = <0 0x10200620 0 0x20>; 303 }; 304 305 systimer: timer@10200670 { 306 compatible = "mediatek,mt6795-systimer"; 307 reg = <0 0x10200670 0 0x10>; 308 interrupts = <GIC_SPI 64 IRQ_TYPE_LEVEL_HIGH>; 309 clocks = <&system_clk>; 310 clock-names = "clk13m"; 311 }; 312 313 gic: interrupt-controller@10221000 { 314 compatible = "arm,gic-400"; 315 #interrupt-cells = <3>; 316 interrupt-parent = <&gic>; 317 interrupt-controller; 318 reg = <0 0x10221000 0 0x1000>, 319 <0 0x10222000 0 0x2000>, 320 <0 0x10224000 0 0x2000>, 321 <0 0x10226000 0 0x2000>; 322 interrupts = <GIC_PPI 9 323 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>; 324 }; 325 326 cci: cci@10390000 { 327 compatible = "arm,cci-400"; 328 #address-cells = <1>; 329 #size-cells = <1>; 330 reg = <0 0x10390000 0 0x1000>; 331 ranges = <0 0 0x10390000 0x10000>; 332 333 cci_control0: slave-if@1000 { 334 compatible = "arm,cci-400-ctrl-if"; 335 interface-type = "ace-lite"; 336 reg = <0x1000 0x1000>; 337 }; 338 339 cci_control1: slave-if@4000 { 340 compatible = "arm,cci-400-ctrl-if"; 341 interface-type = "ace"; 342 reg = <0x4000 0x1000>; 343 }; 344 345 cci_control2: slave-if@5000 { 346 compatible = "arm,cci-400-ctrl-if"; 347 interface-type = "ace"; 348 reg = <0x5000 0x1000>; 349 }; 350 351 pmu@9000 { 352 compatible = "arm,cci-400-pmu,r1"; 353 reg = <0x9000 0x5000>; 354 interrupts = <GIC_SPI 58 IRQ_TYPE_LEVEL_HIGH>, 355 <GIC_SPI 59 IRQ_TYPE_LEVEL_HIGH>, 356 <GIC_SPI 60 IRQ_TYPE_LEVEL_HIGH>, 357 <GIC_SPI 61 IRQ_TYPE_LEVEL_HIGH>, 358 <GIC_SPI 62 IRQ_TYPE_LEVEL_HIGH>; 359 }; 360 }; 361 362 uart0: serial@11002000 { 363 compatible = "mediatek,mt6795-uart", 364 "mediatek,mt6577-uart"; 365 reg = <0 0x11002000 0 0x400>; 366 interrupts = <GIC_SPI 91 IRQ_TYPE_LEVEL_LOW>; 367 clocks = <&pericfg CLK_PERI_UART0_SEL>, <&pericfg CLK_PERI_UART0>; 368 clock-names = "baud", "bus"; 369 dmas = <&apdma 0>, <&apdma 1>; 370 dma-names = "tx", "rx"; 371 status = "disabled"; 372 }; 373 374 uart1: serial@11003000 { 375 compatible = "mediatek,mt6795-uart", 376 "mediatek,mt6577-uart"; 377 reg = <0 0x11003000 0 0x400>; 378 interrupts = <GIC_SPI 92 IRQ_TYPE_LEVEL_LOW>; 379 clocks = <&pericfg CLK_PERI_UART1_SEL>, <&pericfg CLK_PERI_UART1>; 380 clock-names = "baud", "bus"; 381 dmas = <&apdma 2>, <&apdma 3>; 382 dma-names = "tx", "rx"; 383 status = "disabled"; 384 }; 385 386 apdma: dma-controller@11000380 { 387 compatible = "mediatek,mt6795-uart-dma", 388 "mediatek,mt6577-uart-dma"; 389 reg = <0 0x11000380 0 0x60>, 390 <0 0x11000400 0 0x60>, 391 <0 0x11000480 0 0x60>, 392 <0 0x11000500 0 0x60>, 393 <0 0x11000580 0 0x60>, 394 <0 0x11000600 0 0x60>, 395 <0 0x11000680 0 0x60>, 396 <0 0x11000700 0 0x60>; 397 interrupts = <GIC_SPI 103 IRQ_TYPE_LEVEL_LOW>, 398 <GIC_SPI 104 IRQ_TYPE_LEVEL_LOW>, 399 <GIC_SPI 105 IRQ_TYPE_LEVEL_LOW>, 400 <GIC_SPI 106 IRQ_TYPE_LEVEL_LOW>, 401 <GIC_SPI 107 IRQ_TYPE_LEVEL_LOW>, 402 <GIC_SPI 108 IRQ_TYPE_LEVEL_LOW>, 403 <GIC_SPI 109 IRQ_TYPE_LEVEL_LOW>, 404 <GIC_SPI 110 IRQ_TYPE_LEVEL_LOW>; 405 dma-requests = <8>; 406 clocks = <&pericfg CLK_PERI_AP_DMA>; 407 clock-names = "apdma"; 408 mediatek,dma-33bits; 409 #dma-cells = <1>; 410 }; 411 412 uart2: serial@11004000 { 413 compatible = "mediatek,mt6795-uart", 414 "mediatek,mt6577-uart"; 415 reg = <0 0x11004000 0 0x400>; 416 interrupts = <GIC_SPI 93 IRQ_TYPE_LEVEL_LOW>; 417 clocks = <&pericfg CLK_PERI_UART2_SEL>, <&pericfg CLK_PERI_UART2>; 418 clock-names = "baud", "bus"; 419 dmas = <&apdma 4>, <&apdma 5>; 420 dma-names = "tx", "rx"; 421 status = "disabled"; 422 }; 423 424 uart3: serial@11005000 { 425 compatible = "mediatek,mt6795-uart", 426 "mediatek,mt6577-uart"; 427 reg = <0 0x11005000 0 0x400>; 428 interrupts = <GIC_SPI 94 IRQ_TYPE_LEVEL_LOW>; 429 clocks = <&pericfg CLK_PERI_UART3_SEL>, <&pericfg CLK_PERI_UART3>; 430 clock-names = "baud", "bus"; 431 dmas = <&apdma 6>, <&apdma 7>; 432 dma-names = "tx", "rx"; 433 status = "disabled"; 434 }; 435 436 mmc0: mmc@11230000 { 437 compatible = "mediatek,mt6795-mmc"; 438 reg = <0 0x11230000 0 0x1000>; 439 interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_LOW>; 440 clocks = <&pericfg CLK_PERI_MSDC30_0>, 441 <&topckgen CLK_TOP_MSDC50_0_H_SEL>, 442 <&topckgen CLK_TOP_MSDC50_0_SEL>; 443 clock-names = "source", "hclk", "source_cg"; 444 status = "disabled"; 445 }; 446 447 mmc1: mmc@11240000 { 448 compatible = "mediatek,mt6795-mmc"; 449 reg = <0 0x11240000 0 0x1000>; 450 interrupts = <GIC_SPI 80 IRQ_TYPE_LEVEL_LOW>; 451 clocks = <&pericfg CLK_PERI_MSDC30_1>, 452 <&topckgen CLK_TOP_AXI_SEL>; 453 clock-names = "source", "hclk"; 454 status = "disabled"; 455 }; 456 457 mmc2: mmc@11250000 { 458 compatible = "mediatek,mt6795-mmc"; 459 reg = <0 0x11250000 0 0x1000>; 460 interrupts = <GIC_SPI 81 IRQ_TYPE_LEVEL_LOW>; 461 clocks = <&pericfg CLK_PERI_MSDC30_2>, 462 <&topckgen CLK_TOP_AXI_SEL>; 463 clock-names = "source", "hclk"; 464 status = "disabled"; 465 }; 466 467 mmc3: mmc@11260000 { 468 compatible = "mediatek,mt6795-mmc"; 469 reg = <0 0x11260000 0 0x1000>; 470 interrupts = <GIC_SPI 82 IRQ_TYPE_LEVEL_LOW>; 471 clocks = <&pericfg CLK_PERI_MSDC30_3>, 472 <&topckgen CLK_TOP_AXI_SEL>; 473 clock-names = "source", "hclk"; 474 status = "disabled"; 475 }; 476 }; 477}; 478