18c2ecf20Sopenharmony_ci# SPDX-License-Identifier: (GPL-2.0-only or BSD-2-Clause) 28c2ecf20Sopenharmony_ci%YAML 1.2 38c2ecf20Sopenharmony_ci--- 48c2ecf20Sopenharmony_ci$id: http://devicetree.org/schemas/remoteproc/ti,k3-r5f-rproc.yaml# 58c2ecf20Sopenharmony_ci$schema: http://devicetree.org/meta-schemas/core.yaml# 68c2ecf20Sopenharmony_ci 78c2ecf20Sopenharmony_cititle: TI K3 R5F processor subsystems 88c2ecf20Sopenharmony_ci 98c2ecf20Sopenharmony_cimaintainers: 108c2ecf20Sopenharmony_ci - Suman Anna <s-anna@ti.com> 118c2ecf20Sopenharmony_ci 128c2ecf20Sopenharmony_cidescription: | 138c2ecf20Sopenharmony_ci The TI K3 family of SoCs usually have one or more dual-core Arm Cortex R5F 148c2ecf20Sopenharmony_ci processor subsystems/clusters (R5FSS). The dual core cluster can be used 158c2ecf20Sopenharmony_ci either in a LockStep mode providing safety/fault tolerance features or in a 168c2ecf20Sopenharmony_ci Split mode providing two individual compute cores for doubling the compute 178c2ecf20Sopenharmony_ci capacity. These are used together with other processors present on the SoC 188c2ecf20Sopenharmony_ci to achieve various system level goals. 198c2ecf20Sopenharmony_ci 208c2ecf20Sopenharmony_ci Each Dual-Core R5F sub-system is represented as a single DTS node 218c2ecf20Sopenharmony_ci representing the cluster, with a pair of child DT nodes representing 228c2ecf20Sopenharmony_ci the individual R5F cores. Each node has a number of required or optional 238c2ecf20Sopenharmony_ci properties that enable the OS running on the host processor to perform 248c2ecf20Sopenharmony_ci the device management of the remote processor and to communicate with the 258c2ecf20Sopenharmony_ci remote processor. 268c2ecf20Sopenharmony_ci 278c2ecf20Sopenharmony_ciproperties: 288c2ecf20Sopenharmony_ci $nodename: 298c2ecf20Sopenharmony_ci pattern: "^r5fss(@.*)?" 308c2ecf20Sopenharmony_ci 318c2ecf20Sopenharmony_ci compatible: 328c2ecf20Sopenharmony_ci enum: 338c2ecf20Sopenharmony_ci - ti,am654-r5fss 348c2ecf20Sopenharmony_ci - ti,j721e-r5fss 358c2ecf20Sopenharmony_ci 368c2ecf20Sopenharmony_ci power-domains: 378c2ecf20Sopenharmony_ci description: | 388c2ecf20Sopenharmony_ci Should contain a phandle to a PM domain provider node and an args 398c2ecf20Sopenharmony_ci specifier containing the R5FSS device id value. 408c2ecf20Sopenharmony_ci maxItems: 1 418c2ecf20Sopenharmony_ci 428c2ecf20Sopenharmony_ci "#address-cells": 438c2ecf20Sopenharmony_ci const: 1 448c2ecf20Sopenharmony_ci 458c2ecf20Sopenharmony_ci "#size-cells": 468c2ecf20Sopenharmony_ci const: 1 478c2ecf20Sopenharmony_ci 488c2ecf20Sopenharmony_ci ranges: 498c2ecf20Sopenharmony_ci description: | 508c2ecf20Sopenharmony_ci Standard ranges definition providing address translations for 518c2ecf20Sopenharmony_ci local R5F TCM address spaces to bus addresses. 528c2ecf20Sopenharmony_ci 538c2ecf20Sopenharmony_ci# Optional properties: 548c2ecf20Sopenharmony_ci# -------------------- 558c2ecf20Sopenharmony_ci 568c2ecf20Sopenharmony_ci ti,cluster-mode: 578c2ecf20Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/uint32 588c2ecf20Sopenharmony_ci enum: [0, 1] 598c2ecf20Sopenharmony_ci description: | 608c2ecf20Sopenharmony_ci Configuration Mode for the Dual R5F cores within the R5F cluster. 618c2ecf20Sopenharmony_ci Should be either a value of 1 (LockStep mode) or 0 (Split mode), 628c2ecf20Sopenharmony_ci default is LockStep mode if omitted. 638c2ecf20Sopenharmony_ci 648c2ecf20Sopenharmony_ci# R5F Processor Child Nodes: 658c2ecf20Sopenharmony_ci# ========================== 668c2ecf20Sopenharmony_ci 678c2ecf20Sopenharmony_cipatternProperties: 688c2ecf20Sopenharmony_ci "^r5f@[a-f0-9]+$": 698c2ecf20Sopenharmony_ci type: object 708c2ecf20Sopenharmony_ci description: | 718c2ecf20Sopenharmony_ci The R5F Sub-System device node should define two R5F child nodes, each 728c2ecf20Sopenharmony_ci node representing a TI instantiation of the Arm Cortex R5F core. There 738c2ecf20Sopenharmony_ci are some specific integration differences for the IP like the usage of 748c2ecf20Sopenharmony_ci a Region Address Translator (RAT) for translating the larger SoC bus 758c2ecf20Sopenharmony_ci addresses into a 32-bit address space for the processor. 768c2ecf20Sopenharmony_ci 778c2ecf20Sopenharmony_ci Each R5F core has an associated 64 KB of Tightly-Coupled Memory (TCM) 788c2ecf20Sopenharmony_ci internal memories split between two banks - TCMA and TCMB (further 798c2ecf20Sopenharmony_ci interleaved into two banks TCMB0 and TCMB1). These memories (also called 808c2ecf20Sopenharmony_ci ATCM and BTCM) provide read/write performance on par with the core's L1 818c2ecf20Sopenharmony_ci caches. Each of the TCMs can be enabled or disabled independently and 828c2ecf20Sopenharmony_ci either of them can be configured to appear at that R5F's address 0x0. 838c2ecf20Sopenharmony_ci 848c2ecf20Sopenharmony_ci The cores do not use an MMU, but has a Region Address Translater 858c2ecf20Sopenharmony_ci (RAT) module that is accessible only from the R5Fs for providing 868c2ecf20Sopenharmony_ci translations between 32-bit CPU addresses into larger system bus 878c2ecf20Sopenharmony_ci addresses. Cache and memory access settings are provided through a 888c2ecf20Sopenharmony_ci Memory Protection Unit (MPU), programmable only from the R5Fs. 898c2ecf20Sopenharmony_ci 908c2ecf20Sopenharmony_ci allOf: 918c2ecf20Sopenharmony_ci - $ref: /schemas/arm/keystone/ti,k3-sci-common.yaml# 928c2ecf20Sopenharmony_ci 938c2ecf20Sopenharmony_ci properties: 948c2ecf20Sopenharmony_ci compatible: 958c2ecf20Sopenharmony_ci enum: 968c2ecf20Sopenharmony_ci - ti,am654-r5f 978c2ecf20Sopenharmony_ci - ti,j721e-r5f 988c2ecf20Sopenharmony_ci 998c2ecf20Sopenharmony_ci reg: 1008c2ecf20Sopenharmony_ci items: 1018c2ecf20Sopenharmony_ci - description: Address and Size of the ATCM internal memory region 1028c2ecf20Sopenharmony_ci - description: Address and Size of the BTCM internal memory region 1038c2ecf20Sopenharmony_ci 1048c2ecf20Sopenharmony_ci reg-names: 1058c2ecf20Sopenharmony_ci items: 1068c2ecf20Sopenharmony_ci - const: atcm 1078c2ecf20Sopenharmony_ci - const: btcm 1088c2ecf20Sopenharmony_ci 1098c2ecf20Sopenharmony_ci resets: 1108c2ecf20Sopenharmony_ci description: | 1118c2ecf20Sopenharmony_ci Should contain the phandle to the reset controller node managing the 1128c2ecf20Sopenharmony_ci local resets for this device, and a reset specifier. 1138c2ecf20Sopenharmony_ci maxItems: 1 1148c2ecf20Sopenharmony_ci 1158c2ecf20Sopenharmony_ci firmware-name: 1168c2ecf20Sopenharmony_ci description: | 1178c2ecf20Sopenharmony_ci Should contain the name of the default firmware image 1188c2ecf20Sopenharmony_ci file located on the firmware search path 1198c2ecf20Sopenharmony_ci 1208c2ecf20Sopenharmony_ci# The following properties are mandatory for R5F Core0 in both LockStep and Split 1218c2ecf20Sopenharmony_ci# modes, and are mandatory for R5F Core1 _only_ in Split mode. They are unused for 1228c2ecf20Sopenharmony_ci# R5F Core1 in LockStep mode: 1238c2ecf20Sopenharmony_ci 1248c2ecf20Sopenharmony_ci mboxes: 1258c2ecf20Sopenharmony_ci description: | 1268c2ecf20Sopenharmony_ci OMAP Mailbox specifier denoting the sub-mailbox, to be used for 1278c2ecf20Sopenharmony_ci communication with the remote processor. This property should match 1288c2ecf20Sopenharmony_ci with the sub-mailbox node used in the firmware image. 1298c2ecf20Sopenharmony_ci maxItems: 1 1308c2ecf20Sopenharmony_ci 1318c2ecf20Sopenharmony_ci memory-region: 1328c2ecf20Sopenharmony_ci description: | 1338c2ecf20Sopenharmony_ci phandle to the reserved memory nodes to be associated with the 1348c2ecf20Sopenharmony_ci remoteproc device. There should be at least two reserved memory nodes 1358c2ecf20Sopenharmony_ci defined. The reserved memory nodes should be carveout nodes, and 1368c2ecf20Sopenharmony_ci should be defined with a "no-map" property as per the bindings in 1378c2ecf20Sopenharmony_ci Documentation/devicetree/bindings/reserved-memory/reserved-memory.txt 1388c2ecf20Sopenharmony_ci minItems: 2 1398c2ecf20Sopenharmony_ci maxItems: 8 1408c2ecf20Sopenharmony_ci items: 1418c2ecf20Sopenharmony_ci - description: region used for dynamic DMA allocations like vrings and 1428c2ecf20Sopenharmony_ci vring buffers 1438c2ecf20Sopenharmony_ci - description: region reserved for firmware image sections 1448c2ecf20Sopenharmony_ci additionalItems: true 1458c2ecf20Sopenharmony_ci 1468c2ecf20Sopenharmony_ci 1478c2ecf20Sopenharmony_ci# Optional properties: 1488c2ecf20Sopenharmony_ci# -------------------- 1498c2ecf20Sopenharmony_ci# The following properties are optional properties for each of the R5F cores: 1508c2ecf20Sopenharmony_ci 1518c2ecf20Sopenharmony_ci ti,atcm-enable: 1528c2ecf20Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/uint32 1538c2ecf20Sopenharmony_ci enum: [0, 1] 1548c2ecf20Sopenharmony_ci description: | 1558c2ecf20Sopenharmony_ci R5F core configuration mode dictating if ATCM should be enabled. The 1568c2ecf20Sopenharmony_ci R5F address of ATCM is dictated by ti,loczrama property. Should be 1578c2ecf20Sopenharmony_ci either a value of 1 (enabled) or 0 (disabled), default is disabled 1588c2ecf20Sopenharmony_ci if omitted. Recommended to enable it for maximizing TCMs. 1598c2ecf20Sopenharmony_ci 1608c2ecf20Sopenharmony_ci ti,btcm-enable: 1618c2ecf20Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/uint32 1628c2ecf20Sopenharmony_ci enum: [0, 1] 1638c2ecf20Sopenharmony_ci description: | 1648c2ecf20Sopenharmony_ci R5F core configuration mode dictating if BTCM should be enabled. The 1658c2ecf20Sopenharmony_ci R5F address of BTCM is dictated by ti,loczrama property. Should be 1668c2ecf20Sopenharmony_ci either a value of 1 (enabled) or 0 (disabled), default is enabled if 1678c2ecf20Sopenharmony_ci omitted. 1688c2ecf20Sopenharmony_ci 1698c2ecf20Sopenharmony_ci ti,loczrama: 1708c2ecf20Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/uint32 1718c2ecf20Sopenharmony_ci enum: [0, 1] 1728c2ecf20Sopenharmony_ci description: | 1738c2ecf20Sopenharmony_ci R5F core configuration mode dictating which TCM should appear at 1748c2ecf20Sopenharmony_ci address 0 (from core's view). Should be either a value of 1 (ATCM 1758c2ecf20Sopenharmony_ci at 0x0) or 0 (BTCM at 0x0), default value is 1 if omitted. 1768c2ecf20Sopenharmony_ci 1778c2ecf20Sopenharmony_ci sram: 1788c2ecf20Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/phandle-array 1798c2ecf20Sopenharmony_ci minItems: 1 1808c2ecf20Sopenharmony_ci maxItems: 4 1818c2ecf20Sopenharmony_ci description: | 1828c2ecf20Sopenharmony_ci phandles to one or more reserved on-chip SRAM regions. The regions 1838c2ecf20Sopenharmony_ci should be defined as child nodes of the respective SRAM node, and 1848c2ecf20Sopenharmony_ci should be defined as per the generic bindings in, 1858c2ecf20Sopenharmony_ci Documentation/devicetree/bindings/sram/sram.yaml 1868c2ecf20Sopenharmony_ci 1878c2ecf20Sopenharmony_ci required: 1888c2ecf20Sopenharmony_ci - compatible 1898c2ecf20Sopenharmony_ci - reg 1908c2ecf20Sopenharmony_ci - reg-names 1918c2ecf20Sopenharmony_ci - ti,sci 1928c2ecf20Sopenharmony_ci - ti,sci-dev-id 1938c2ecf20Sopenharmony_ci - ti,sci-proc-ids 1948c2ecf20Sopenharmony_ci - resets 1958c2ecf20Sopenharmony_ci - firmware-name 1968c2ecf20Sopenharmony_ci 1978c2ecf20Sopenharmony_ci unevaluatedProperties: false 1988c2ecf20Sopenharmony_ci 1998c2ecf20Sopenharmony_cirequired: 2008c2ecf20Sopenharmony_ci - compatible 2018c2ecf20Sopenharmony_ci - power-domains 2028c2ecf20Sopenharmony_ci - "#address-cells" 2038c2ecf20Sopenharmony_ci - "#size-cells" 2048c2ecf20Sopenharmony_ci - ranges 2058c2ecf20Sopenharmony_ci 2068c2ecf20Sopenharmony_ciadditionalProperties: false 2078c2ecf20Sopenharmony_ci 2088c2ecf20Sopenharmony_ciexamples: 2098c2ecf20Sopenharmony_ci - | 2108c2ecf20Sopenharmony_ci / { 2118c2ecf20Sopenharmony_ci model = "Texas Instruments K3 AM654 SoC"; 2128c2ecf20Sopenharmony_ci compatible = "ti,am654-evm", "ti,am654"; 2138c2ecf20Sopenharmony_ci #address-cells = <2>; 2148c2ecf20Sopenharmony_ci #size-cells = <2>; 2158c2ecf20Sopenharmony_ci 2168c2ecf20Sopenharmony_ci bus@100000 { 2178c2ecf20Sopenharmony_ci compatible = "simple-bus"; 2188c2ecf20Sopenharmony_ci #address-cells = <2>; 2198c2ecf20Sopenharmony_ci #size-cells = <2>; 2208c2ecf20Sopenharmony_ci ranges = <0x00 0x00100000 0x00 0x00100000 0x00 0x00020000>, /* ctrl mmr */ 2218c2ecf20Sopenharmony_ci <0x00 0x41000000 0x00 0x41000000 0x00 0x00020000>, 2228c2ecf20Sopenharmony_ci <0x00 0x41400000 0x00 0x41400000 0x00 0x00020000>, 2238c2ecf20Sopenharmony_ci <0x00 0x41c00000 0x00 0x41c00000 0x00 0x00080000>; 2248c2ecf20Sopenharmony_ci 2258c2ecf20Sopenharmony_ci bus@28380000 { 2268c2ecf20Sopenharmony_ci compatible = "simple-bus"; 2278c2ecf20Sopenharmony_ci #address-cells = <2>; 2288c2ecf20Sopenharmony_ci #size-cells = <2>; 2298c2ecf20Sopenharmony_ci ranges = <0x00 0x28380000 0x00 0x28380000 0x00 0x03880000>, /* MCU NAVSS */ 2308c2ecf20Sopenharmony_ci <0x00 0x41000000 0x00 0x41000000 0x00 0x00020000>, /* MCU R5F Core0 */ 2318c2ecf20Sopenharmony_ci <0x00 0x41400000 0x00 0x41400000 0x00 0x00020000>, /* MCU R5F Core1 */ 2328c2ecf20Sopenharmony_ci <0x00 0x41c00000 0x00 0x41c00000 0x00 0x00080000>; /* MCU SRAM */ 2338c2ecf20Sopenharmony_ci 2348c2ecf20Sopenharmony_ci /* AM65x MCU R5FSS node */ 2358c2ecf20Sopenharmony_ci mcu_r5fss0: r5fss@41000000 { 2368c2ecf20Sopenharmony_ci compatible = "ti,am654-r5fss"; 2378c2ecf20Sopenharmony_ci power-domains = <&k3_pds 129>; 2388c2ecf20Sopenharmony_ci ti,cluster-mode = <1>; 2398c2ecf20Sopenharmony_ci #address-cells = <1>; 2408c2ecf20Sopenharmony_ci #size-cells = <1>; 2418c2ecf20Sopenharmony_ci ranges = <0x41000000 0x00 0x41000000 0x20000>, 2428c2ecf20Sopenharmony_ci <0x41400000 0x00 0x41400000 0x20000>; 2438c2ecf20Sopenharmony_ci 2448c2ecf20Sopenharmony_ci mcu_r5f0: r5f@41000000 { 2458c2ecf20Sopenharmony_ci compatible = "ti,am654-r5f"; 2468c2ecf20Sopenharmony_ci reg = <0x41000000 0x00008000>, 2478c2ecf20Sopenharmony_ci <0x41010000 0x00008000>; 2488c2ecf20Sopenharmony_ci reg-names = "atcm", "btcm"; 2498c2ecf20Sopenharmony_ci ti,sci = <&dmsc>; 2508c2ecf20Sopenharmony_ci ti,sci-dev-id = <159>; 2518c2ecf20Sopenharmony_ci ti,sci-proc-ids = <0x01 0xFF>; 2528c2ecf20Sopenharmony_ci resets = <&k3_reset 159 1>; 2538c2ecf20Sopenharmony_ci firmware-name = "am65x-mcu-r5f0_0-fw"; 2548c2ecf20Sopenharmony_ci ti,atcm-enable = <1>; 2558c2ecf20Sopenharmony_ci ti,btcm-enable = <1>; 2568c2ecf20Sopenharmony_ci ti,loczrama = <1>; 2578c2ecf20Sopenharmony_ci mboxes = <&mailbox0 &mbox_mcu_r5fss0_core0>; 2588c2ecf20Sopenharmony_ci memory-region = <&mcu_r5fss0_core0_dma_memory_region>, 2598c2ecf20Sopenharmony_ci <&mcu_r5fss0_core0_memory_region>; 2608c2ecf20Sopenharmony_ci sram = <&mcu_r5fss0_core0_sram>; 2618c2ecf20Sopenharmony_ci }; 2628c2ecf20Sopenharmony_ci 2638c2ecf20Sopenharmony_ci mcu_r5f1: r5f@41400000 { 2648c2ecf20Sopenharmony_ci compatible = "ti,am654-r5f"; 2658c2ecf20Sopenharmony_ci reg = <0x41400000 0x00008000>, 2668c2ecf20Sopenharmony_ci <0x41410000 0x00008000>; 2678c2ecf20Sopenharmony_ci reg-names = "atcm", "btcm"; 2688c2ecf20Sopenharmony_ci ti,sci = <&dmsc>; 2698c2ecf20Sopenharmony_ci ti,sci-dev-id = <245>; 2708c2ecf20Sopenharmony_ci ti,sci-proc-ids = <0x02 0xFF>; 2718c2ecf20Sopenharmony_ci resets = <&k3_reset 245 1>; 2728c2ecf20Sopenharmony_ci firmware-name = "am65x-mcu-r5f0_1-fw"; 2738c2ecf20Sopenharmony_ci ti,atcm-enable = <1>; 2748c2ecf20Sopenharmony_ci ti,btcm-enable = <1>; 2758c2ecf20Sopenharmony_ci ti,loczrama = <1>; 2768c2ecf20Sopenharmony_ci mboxes = <&mailbox1 &mbox_mcu_r5fss0_core1>; 2778c2ecf20Sopenharmony_ci }; 2788c2ecf20Sopenharmony_ci }; 2798c2ecf20Sopenharmony_ci }; 2808c2ecf20Sopenharmony_ci }; 2818c2ecf20Sopenharmony_ci }; 282