15f62a964SEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0+ OR MIT 25f62a964SEmmanuel Vadot/* 35f62a964SEmmanuel Vadot * Apple T8011 "A10X" SoC 45f62a964SEmmanuel Vadot * 55f62a964SEmmanuel Vadot * Other names: H9G, "Myst" 65f62a964SEmmanuel Vadot * 75f62a964SEmmanuel Vadot * Copyright (c) 2022, Konrad Dybcio <konradybcio@kernel.org> 85f62a964SEmmanuel Vadot */ 95f62a964SEmmanuel Vadot 105f62a964SEmmanuel Vadot#include <dt-bindings/gpio/gpio.h> 115f62a964SEmmanuel Vadot#include <dt-bindings/interrupt-controller/apple-aic.h> 125f62a964SEmmanuel Vadot#include <dt-bindings/interrupt-controller/irq.h> 135f62a964SEmmanuel Vadot#include <dt-bindings/pinctrl/apple.h> 145f62a964SEmmanuel Vadot 155f62a964SEmmanuel Vadot/ { 165f62a964SEmmanuel Vadot interrupt-parent = <&aic>; 175f62a964SEmmanuel Vadot #address-cells = <2>; 185f62a964SEmmanuel Vadot #size-cells = <2>; 195f62a964SEmmanuel Vadot 205f62a964SEmmanuel Vadot clkref: clock-ref { 215f62a964SEmmanuel Vadot compatible = "fixed-clock"; 225f62a964SEmmanuel Vadot #clock-cells = <0>; 235f62a964SEmmanuel Vadot clock-frequency = <24000000>; 245f62a964SEmmanuel Vadot clock-output-names = "clkref"; 255f62a964SEmmanuel Vadot }; 265f62a964SEmmanuel Vadot 275f62a964SEmmanuel Vadot cpus { 285f62a964SEmmanuel Vadot #address-cells = <2>; 295f62a964SEmmanuel Vadot #size-cells = <0>; 305f62a964SEmmanuel Vadot 315f62a964SEmmanuel Vadot cpu0: cpu@0 { 325f62a964SEmmanuel Vadot compatible = "apple,hurricane-zephyr"; 335f62a964SEmmanuel Vadot reg = <0x0 0x0>; 345f62a964SEmmanuel Vadot cpu-release-addr = <0 0>; /* To be filled by loader */ 358ccc0d23SEmmanuel Vadot operating-points-v2 = <&fusion_opp>; 368ccc0d23SEmmanuel Vadot performance-domains = <&cpufreq>; 375f62a964SEmmanuel Vadot enable-method = "spin-table"; 385f62a964SEmmanuel Vadot device_type = "cpu"; 39*ae5de77eSEmmanuel Vadot next-level-cache = <&l2_cache>; 40*ae5de77eSEmmanuel Vadot i-cache-size = <0x10000>; /* P-core */ 41*ae5de77eSEmmanuel Vadot d-cache-size = <0x10000>; /* P-core */ 425f62a964SEmmanuel Vadot }; 435f62a964SEmmanuel Vadot 445f62a964SEmmanuel Vadot cpu1: cpu@1 { 455f62a964SEmmanuel Vadot compatible = "apple,hurricane-zephyr"; 465f62a964SEmmanuel Vadot reg = <0x0 0x1>; 475f62a964SEmmanuel Vadot cpu-release-addr = <0 0>; /* To be filled by loader */ 488ccc0d23SEmmanuel Vadot operating-points-v2 = <&fusion_opp>; 498ccc0d23SEmmanuel Vadot performance-domains = <&cpufreq>; 505f62a964SEmmanuel Vadot enable-method = "spin-table"; 515f62a964SEmmanuel Vadot device_type = "cpu"; 52*ae5de77eSEmmanuel Vadot next-level-cache = <&l2_cache>; 53*ae5de77eSEmmanuel Vadot i-cache-size = <0x10000>; /* P-core */ 54*ae5de77eSEmmanuel Vadot d-cache-size = <0x10000>; /* P-core */ 555f62a964SEmmanuel Vadot }; 565f62a964SEmmanuel Vadot 575f62a964SEmmanuel Vadot cpu2: cpu@2 { 585f62a964SEmmanuel Vadot compatible = "apple,hurricane-zephyr"; 595f62a964SEmmanuel Vadot reg = <0x0 0x2>; 605f62a964SEmmanuel Vadot cpu-release-addr = <0 0>; /* To be filled by loader */ 618ccc0d23SEmmanuel Vadot operating-points-v2 = <&fusion_opp>; 628ccc0d23SEmmanuel Vadot performance-domains = <&cpufreq>; 635f62a964SEmmanuel Vadot enable-method = "spin-table"; 645f62a964SEmmanuel Vadot device_type = "cpu"; 65*ae5de77eSEmmanuel Vadot next-level-cache = <&l2_cache>; 66*ae5de77eSEmmanuel Vadot i-cache-size = <0x10000>; /* P-core */ 67*ae5de77eSEmmanuel Vadot d-cache-size = <0x10000>; /* P-core */ 68*ae5de77eSEmmanuel Vadot }; 69*ae5de77eSEmmanuel Vadot 70*ae5de77eSEmmanuel Vadot l2_cache: l2-cache { 71*ae5de77eSEmmanuel Vadot compatible = "cache"; 72*ae5de77eSEmmanuel Vadot cache-level = <2>; 73*ae5de77eSEmmanuel Vadot cache-unified; 74*ae5de77eSEmmanuel Vadot cache-size = <0x800000>; /* P-cluster */ 755f62a964SEmmanuel Vadot }; 765f62a964SEmmanuel Vadot }; 775f62a964SEmmanuel Vadot 788ccc0d23SEmmanuel Vadot fusion_opp: opp-table { 798ccc0d23SEmmanuel Vadot compatible = "operating-points-v2"; 808ccc0d23SEmmanuel Vadot 818ccc0d23SEmmanuel Vadot /* 828ccc0d23SEmmanuel Vadot * Apple Fusion Architecture: Hardwired big.LITTLE switcher 838ccc0d23SEmmanuel Vadot * that use p-state transitions to switch between cores. 848ccc0d23SEmmanuel Vadot * 858ccc0d23SEmmanuel Vadot * The E-core frequencies are adjusted so performance scales 868ccc0d23SEmmanuel Vadot * linearly with reported clock speed. 878ccc0d23SEmmanuel Vadot */ 888ccc0d23SEmmanuel Vadot 898ccc0d23SEmmanuel Vadot opp01 { 908ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <172000000>; /* 300 MHz, E-core */ 918ccc0d23SEmmanuel Vadot opp-level = <1>; 928ccc0d23SEmmanuel Vadot clock-latency-ns = <12000>; 938ccc0d23SEmmanuel Vadot }; 948ccc0d23SEmmanuel Vadot opp02 { 958ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <230000000>; /* 396 MHz, E-core */ 968ccc0d23SEmmanuel Vadot opp-level = <2>; 978ccc0d23SEmmanuel Vadot clock-latency-ns = <135000>; 988ccc0d23SEmmanuel Vadot }; 998ccc0d23SEmmanuel Vadot opp03 { 1008ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <448000000>; /* 768 MHz, E-core */ 1018ccc0d23SEmmanuel Vadot opp-level = <3>; 1028ccc0d23SEmmanuel Vadot clock-latency-ns = <105000>; 1038ccc0d23SEmmanuel Vadot }; 1048ccc0d23SEmmanuel Vadot opp04 { 1058ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <662000000>; /* 1152 MHz, E-core */ 1068ccc0d23SEmmanuel Vadot opp-level = <4>; 1078ccc0d23SEmmanuel Vadot clock-latency-ns = <115000>; 1088ccc0d23SEmmanuel Vadot }; 1098ccc0d23SEmmanuel Vadot opp05 { 1108ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <804000000>; 1118ccc0d23SEmmanuel Vadot opp-level = <5>; 1128ccc0d23SEmmanuel Vadot clock-latency-ns = <122000>; 1138ccc0d23SEmmanuel Vadot }; 1148ccc0d23SEmmanuel Vadot opp06 { 1158ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <1140000000>; 1168ccc0d23SEmmanuel Vadot opp-level = <6>; 1178ccc0d23SEmmanuel Vadot clock-latency-ns = <120000>; 1188ccc0d23SEmmanuel Vadot }; 1198ccc0d23SEmmanuel Vadot opp07 { 1208ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <1548000000>; 1218ccc0d23SEmmanuel Vadot opp-level = <7>; 1228ccc0d23SEmmanuel Vadot clock-latency-ns = <125000>; 1238ccc0d23SEmmanuel Vadot }; 1248ccc0d23SEmmanuel Vadot opp08 { 1258ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <1956000000>; 1268ccc0d23SEmmanuel Vadot opp-level = <8>; 1278ccc0d23SEmmanuel Vadot clock-latency-ns = <135000>; 1288ccc0d23SEmmanuel Vadot }; 1298ccc0d23SEmmanuel Vadot opp09 { 1308ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <2316000000>; 1318ccc0d23SEmmanuel Vadot opp-level = <9>; 1328ccc0d23SEmmanuel Vadot clock-latency-ns = <140000>; 1338ccc0d23SEmmanuel Vadot }; 1348ccc0d23SEmmanuel Vadot#if 0 1358ccc0d23SEmmanuel Vadot /* Not available until CPU deep sleep is implemented */ 1368ccc0d23SEmmanuel Vadot opp10 { 1378ccc0d23SEmmanuel Vadot opp-hz = /bits/ 64 <2400000000>; 1388ccc0d23SEmmanuel Vadot opp-level = <10>; 1398ccc0d23SEmmanuel Vadot clock-latency-ns = <140000>; 1408ccc0d23SEmmanuel Vadot turbo-mode; 1418ccc0d23SEmmanuel Vadot }; 1428ccc0d23SEmmanuel Vadot#endif 1438ccc0d23SEmmanuel Vadot }; 1448ccc0d23SEmmanuel Vadot 1455f62a964SEmmanuel Vadot soc { 1465f62a964SEmmanuel Vadot compatible = "simple-bus"; 1475f62a964SEmmanuel Vadot #address-cells = <2>; 1485f62a964SEmmanuel Vadot #size-cells = <2>; 1495f62a964SEmmanuel Vadot nonposted-mmio; 1505f62a964SEmmanuel Vadot ranges; 1515f62a964SEmmanuel Vadot 1528ccc0d23SEmmanuel Vadot cpufreq: performance-controller@202f20000 { 1538ccc0d23SEmmanuel Vadot compatible = "apple,t8010-cluster-cpufreq", "apple,t8103-cluster-cpufreq", "apple,cluster-cpufreq"; 1548ccc0d23SEmmanuel Vadot reg = <0x2 0x02f20000 0 0x1000>; 1558ccc0d23SEmmanuel Vadot #performance-domain-cells = <0>; 1568ccc0d23SEmmanuel Vadot }; 1578ccc0d23SEmmanuel Vadot 1585f62a964SEmmanuel Vadot serial0: serial@20a0c0000 { 1595f62a964SEmmanuel Vadot compatible = "apple,s5l-uart"; 1605f62a964SEmmanuel Vadot reg = <0x2 0x0a0c0000 0x0 0x4000>; 1615f62a964SEmmanuel Vadot reg-io-width = <4>; 1625f62a964SEmmanuel Vadot interrupt-parent = <&aic>; 1635f62a964SEmmanuel Vadot interrupts = <AIC_IRQ 216 IRQ_TYPE_LEVEL_HIGH>; 1645f62a964SEmmanuel Vadot /* Use the bootloader-enabled clocks for now. */ 1655f62a964SEmmanuel Vadot clocks = <&clkref>, <&clkref>; 1665f62a964SEmmanuel Vadot clock-names = "uart", "clk_uart_baud0"; 1678ccc0d23SEmmanuel Vadot power-domains = <&ps_uart0>; 1685f62a964SEmmanuel Vadot status = "disabled"; 1695f62a964SEmmanuel Vadot }; 1705f62a964SEmmanuel Vadot 1718ccc0d23SEmmanuel Vadot pmgr: power-management@20e000000 { 1728ccc0d23SEmmanuel Vadot compatible = "apple,t8010-pmgr", "apple,pmgr", "syscon", "simple-mfd"; 1738ccc0d23SEmmanuel Vadot #address-cells = <1>; 1748ccc0d23SEmmanuel Vadot #size-cells = <1>; 1758ccc0d23SEmmanuel Vadot 1768ccc0d23SEmmanuel Vadot reg = <0x2 0xe000000 0 0x8c000>; 1778ccc0d23SEmmanuel Vadot }; 1788ccc0d23SEmmanuel Vadot 1795f62a964SEmmanuel Vadot aic: interrupt-controller@20e100000 { 1805f62a964SEmmanuel Vadot compatible = "apple,t8010-aic", "apple,aic"; 1815f62a964SEmmanuel Vadot reg = <0x2 0x0e100000 0x0 0x100000>; 1825f62a964SEmmanuel Vadot #interrupt-cells = <3>; 1835f62a964SEmmanuel Vadot interrupt-controller; 1848ccc0d23SEmmanuel Vadot power-domains = <&ps_aic>; 1855f62a964SEmmanuel Vadot }; 1865f62a964SEmmanuel Vadot 1875f62a964SEmmanuel Vadot pinctrl_ap: pinctrl@20f100000 { 1885f62a964SEmmanuel Vadot compatible = "apple,t8010-pinctrl", "apple,pinctrl"; 1895f62a964SEmmanuel Vadot reg = <0x2 0x0f100000 0x0 0x100000>; 1908ccc0d23SEmmanuel Vadot power-domains = <&ps_gpio>; 1915f62a964SEmmanuel Vadot 1925f62a964SEmmanuel Vadot gpio-controller; 1935f62a964SEmmanuel Vadot #gpio-cells = <2>; 1945f62a964SEmmanuel Vadot gpio-ranges = <&pinctrl_ap 0 0 219>; 1955f62a964SEmmanuel Vadot apple,npins = <219>; 1965f62a964SEmmanuel Vadot 1975f62a964SEmmanuel Vadot interrupt-controller; 1985f62a964SEmmanuel Vadot #interrupt-cells = <2>; 1995f62a964SEmmanuel Vadot interrupt-parent = <&aic>; 2005f62a964SEmmanuel Vadot interrupts = <AIC_IRQ 42 IRQ_TYPE_LEVEL_HIGH>, 2015f62a964SEmmanuel Vadot <AIC_IRQ 43 IRQ_TYPE_LEVEL_HIGH>, 2025f62a964SEmmanuel Vadot <AIC_IRQ 44 IRQ_TYPE_LEVEL_HIGH>, 2035f62a964SEmmanuel Vadot <AIC_IRQ 45 IRQ_TYPE_LEVEL_HIGH>, 2045f62a964SEmmanuel Vadot <AIC_IRQ 46 IRQ_TYPE_LEVEL_HIGH>, 2055f62a964SEmmanuel Vadot <AIC_IRQ 47 IRQ_TYPE_LEVEL_HIGH>, 2065f62a964SEmmanuel Vadot <AIC_IRQ 48 IRQ_TYPE_LEVEL_HIGH>; 2075f62a964SEmmanuel Vadot }; 2085f62a964SEmmanuel Vadot 2095f62a964SEmmanuel Vadot pinctrl_aop: pinctrl@2100f0000 { 2105f62a964SEmmanuel Vadot compatible = "apple,t8010-pinctrl", "apple,pinctrl"; 2115f62a964SEmmanuel Vadot reg = <0x2 0x100f0000 0x0 0x100000>; 2128ccc0d23SEmmanuel Vadot power-domains = <&ps_aop_gpio>; 2135f62a964SEmmanuel Vadot 2145f62a964SEmmanuel Vadot gpio-controller; 2155f62a964SEmmanuel Vadot #gpio-cells = <2>; 2165f62a964SEmmanuel Vadot gpio-ranges = <&pinctrl_aop 0 0 42>; 2175f62a964SEmmanuel Vadot apple,npins = <42>; 2185f62a964SEmmanuel Vadot 2195f62a964SEmmanuel Vadot interrupt-controller; 2205f62a964SEmmanuel Vadot #interrupt-cells = <2>; 2215f62a964SEmmanuel Vadot interrupt-parent = <&aic>; 2225f62a964SEmmanuel Vadot interrupts = <AIC_IRQ 125 IRQ_TYPE_LEVEL_HIGH>, 2235f62a964SEmmanuel Vadot <AIC_IRQ 126 IRQ_TYPE_LEVEL_HIGH>, 2245f62a964SEmmanuel Vadot <AIC_IRQ 127 IRQ_TYPE_LEVEL_HIGH>, 2255f62a964SEmmanuel Vadot <AIC_IRQ 128 IRQ_TYPE_LEVEL_HIGH>, 2265f62a964SEmmanuel Vadot <AIC_IRQ 129 IRQ_TYPE_LEVEL_HIGH>, 2275f62a964SEmmanuel Vadot <AIC_IRQ 130 IRQ_TYPE_LEVEL_HIGH>, 2285f62a964SEmmanuel Vadot <AIC_IRQ 131 IRQ_TYPE_LEVEL_HIGH>; 2295f62a964SEmmanuel Vadot }; 2305f62a964SEmmanuel Vadot 2318ccc0d23SEmmanuel Vadot pmgr_mini: power-management@210200000 { 2328ccc0d23SEmmanuel Vadot compatible = "apple,t8010-pmgr", "apple,pmgr", "syscon", "simple-mfd"; 2338ccc0d23SEmmanuel Vadot #address-cells = <1>; 2348ccc0d23SEmmanuel Vadot #size-cells = <1>; 2358ccc0d23SEmmanuel Vadot 2368ccc0d23SEmmanuel Vadot reg = <0x2 0x10200000 0 0x84000>; 2378ccc0d23SEmmanuel Vadot }; 2388ccc0d23SEmmanuel Vadot 2395f62a964SEmmanuel Vadot wdt: watchdog@2102b0000 { 2405f62a964SEmmanuel Vadot compatible = "apple,t8010-wdt", "apple,wdt"; 2415f62a964SEmmanuel Vadot reg = <0x2 0x102b0000 0x0 0x4000>; 2425f62a964SEmmanuel Vadot clocks = <&clkref>; 2435f62a964SEmmanuel Vadot interrupt-parent = <&aic>; 2445f62a964SEmmanuel Vadot interrupts = <AIC_IRQ 4 IRQ_TYPE_LEVEL_HIGH>; 2455f62a964SEmmanuel Vadot }; 2465f62a964SEmmanuel Vadot }; 2475f62a964SEmmanuel Vadot 2485f62a964SEmmanuel Vadot timer { 2495f62a964SEmmanuel Vadot compatible = "arm,armv8-timer"; 2505f62a964SEmmanuel Vadot interrupt-parent = <&aic>; 2515f62a964SEmmanuel Vadot interrupt-names = "phys", "virt"; 2525f62a964SEmmanuel Vadot /* Note that A10X doesn't actually have a hypervisor (EL2 is not implemented). */ 2535f62a964SEmmanuel Vadot interrupts = <AIC_FIQ AIC_TMR_GUEST_PHYS IRQ_TYPE_LEVEL_HIGH>, 2545f62a964SEmmanuel Vadot <AIC_FIQ AIC_TMR_GUEST_VIRT IRQ_TYPE_LEVEL_HIGH>; 2555f62a964SEmmanuel Vadot }; 2565f62a964SEmmanuel Vadot}; 2578ccc0d23SEmmanuel Vadot 2588ccc0d23SEmmanuel Vadot#include "t8011-pmgr.dtsi" 259