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 fhctl: clock-controller@10209f00 { 314 compatible = "mediatek,mt6795-fhctl"; 315 reg = <0 0x10209f00 0 0x100>; 316 status = "disabled"; 317 }; 318 319 gic: interrupt-controller@10221000 { 320 compatible = "arm,gic-400"; 321 #interrupt-cells = <3>; 322 interrupt-parent = <&gic>; 323 interrupt-controller; 324 reg = <0 0x10221000 0 0x1000>, 325 <0 0x10222000 0 0x2000>, 326 <0 0x10224000 0 0x2000>, 327 <0 0x10226000 0 0x2000>; 328 interrupts = <GIC_PPI 9 329 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>; 330 }; 331 332 cci: cci@10390000 { 333 compatible = "arm,cci-400"; 334 #address-cells = <1>; 335 #size-cells = <1>; 336 reg = <0 0x10390000 0 0x1000>; 337 ranges = <0 0 0x10390000 0x10000>; 338 339 cci_control0: slave-if@1000 { 340 compatible = "arm,cci-400-ctrl-if"; 341 interface-type = "ace-lite"; 342 reg = <0x1000 0x1000>; 343 }; 344 345 cci_control1: slave-if@4000 { 346 compatible = "arm,cci-400-ctrl-if"; 347 interface-type = "ace"; 348 reg = <0x4000 0x1000>; 349 }; 350 351 cci_control2: slave-if@5000 { 352 compatible = "arm,cci-400-ctrl-if"; 353 interface-type = "ace"; 354 reg = <0x5000 0x1000>; 355 }; 356 357 pmu@9000 { 358 compatible = "arm,cci-400-pmu,r1"; 359 reg = <0x9000 0x5000>; 360 interrupts = <GIC_SPI 58 IRQ_TYPE_LEVEL_HIGH>, 361 <GIC_SPI 59 IRQ_TYPE_LEVEL_HIGH>, 362 <GIC_SPI 60 IRQ_TYPE_LEVEL_HIGH>, 363 <GIC_SPI 61 IRQ_TYPE_LEVEL_HIGH>, 364 <GIC_SPI 62 IRQ_TYPE_LEVEL_HIGH>; 365 }; 366 }; 367 368 uart0: serial@11002000 { 369 compatible = "mediatek,mt6795-uart", 370 "mediatek,mt6577-uart"; 371 reg = <0 0x11002000 0 0x400>; 372 interrupts = <GIC_SPI 91 IRQ_TYPE_LEVEL_LOW>; 373 clocks = <&pericfg CLK_PERI_UART0_SEL>, <&pericfg CLK_PERI_UART0>; 374 clock-names = "baud", "bus"; 375 dmas = <&apdma 0>, <&apdma 1>; 376 dma-names = "tx", "rx"; 377 status = "disabled"; 378 }; 379 380 uart1: serial@11003000 { 381 compatible = "mediatek,mt6795-uart", 382 "mediatek,mt6577-uart"; 383 reg = <0 0x11003000 0 0x400>; 384 interrupts = <GIC_SPI 92 IRQ_TYPE_LEVEL_LOW>; 385 clocks = <&pericfg CLK_PERI_UART1_SEL>, <&pericfg CLK_PERI_UART1>; 386 clock-names = "baud", "bus"; 387 dmas = <&apdma 2>, <&apdma 3>; 388 dma-names = "tx", "rx"; 389 status = "disabled"; 390 }; 391 392 apdma: dma-controller@11000380 { 393 compatible = "mediatek,mt6795-uart-dma", 394 "mediatek,mt6577-uart-dma"; 395 reg = <0 0x11000380 0 0x60>, 396 <0 0x11000400 0 0x60>, 397 <0 0x11000480 0 0x60>, 398 <0 0x11000500 0 0x60>, 399 <0 0x11000580 0 0x60>, 400 <0 0x11000600 0 0x60>, 401 <0 0x11000680 0 0x60>, 402 <0 0x11000700 0 0x60>; 403 interrupts = <GIC_SPI 103 IRQ_TYPE_LEVEL_LOW>, 404 <GIC_SPI 104 IRQ_TYPE_LEVEL_LOW>, 405 <GIC_SPI 105 IRQ_TYPE_LEVEL_LOW>, 406 <GIC_SPI 106 IRQ_TYPE_LEVEL_LOW>, 407 <GIC_SPI 107 IRQ_TYPE_LEVEL_LOW>, 408 <GIC_SPI 108 IRQ_TYPE_LEVEL_LOW>, 409 <GIC_SPI 109 IRQ_TYPE_LEVEL_LOW>, 410 <GIC_SPI 110 IRQ_TYPE_LEVEL_LOW>; 411 dma-requests = <8>; 412 clocks = <&pericfg CLK_PERI_AP_DMA>; 413 clock-names = "apdma"; 414 mediatek,dma-33bits; 415 #dma-cells = <1>; 416 }; 417 418 uart2: serial@11004000 { 419 compatible = "mediatek,mt6795-uart", 420 "mediatek,mt6577-uart"; 421 reg = <0 0x11004000 0 0x400>; 422 interrupts = <GIC_SPI 93 IRQ_TYPE_LEVEL_LOW>; 423 clocks = <&pericfg CLK_PERI_UART2_SEL>, <&pericfg CLK_PERI_UART2>; 424 clock-names = "baud", "bus"; 425 dmas = <&apdma 4>, <&apdma 5>; 426 dma-names = "tx", "rx"; 427 status = "disabled"; 428 }; 429 430 uart3: serial@11005000 { 431 compatible = "mediatek,mt6795-uart", 432 "mediatek,mt6577-uart"; 433 reg = <0 0x11005000 0 0x400>; 434 interrupts = <GIC_SPI 94 IRQ_TYPE_LEVEL_LOW>; 435 clocks = <&pericfg CLK_PERI_UART3_SEL>, <&pericfg CLK_PERI_UART3>; 436 clock-names = "baud", "bus"; 437 dmas = <&apdma 6>, <&apdma 7>; 438 dma-names = "tx", "rx"; 439 status = "disabled"; 440 }; 441 442 mmc0: mmc@11230000 { 443 compatible = "mediatek,mt6795-mmc"; 444 reg = <0 0x11230000 0 0x1000>; 445 interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_LOW>; 446 clocks = <&pericfg CLK_PERI_MSDC30_0>, 447 <&topckgen CLK_TOP_MSDC50_0_H_SEL>, 448 <&topckgen CLK_TOP_MSDC50_0_SEL>; 449 clock-names = "source", "hclk", "source_cg"; 450 status = "disabled"; 451 }; 452 453 mmc1: mmc@11240000 { 454 compatible = "mediatek,mt6795-mmc"; 455 reg = <0 0x11240000 0 0x1000>; 456 interrupts = <GIC_SPI 80 IRQ_TYPE_LEVEL_LOW>; 457 clocks = <&pericfg CLK_PERI_MSDC30_1>, 458 <&topckgen CLK_TOP_AXI_SEL>; 459 clock-names = "source", "hclk"; 460 status = "disabled"; 461 }; 462 463 mmc2: mmc@11250000 { 464 compatible = "mediatek,mt6795-mmc"; 465 reg = <0 0x11250000 0 0x1000>; 466 interrupts = <GIC_SPI 81 IRQ_TYPE_LEVEL_LOW>; 467 clocks = <&pericfg CLK_PERI_MSDC30_2>, 468 <&topckgen CLK_TOP_AXI_SEL>; 469 clock-names = "source", "hclk"; 470 status = "disabled"; 471 }; 472 473 mmc3: mmc@11260000 { 474 compatible = "mediatek,mt6795-mmc"; 475 reg = <0 0x11260000 0 0x1000>; 476 interrupts = <GIC_SPI 82 IRQ_TYPE_LEVEL_LOW>; 477 clocks = <&pericfg CLK_PERI_MSDC30_3>, 478 <&topckgen CLK_TOP_AXI_SEL>; 479 clock-names = "source", "hclk"; 480 status = "disabled"; 481 }; 482 }; 483}; 484