Add R5F nodes on TI K3 J7200 SoCs
Subsystems (2)
v2 cover Add R5F nodes on TI K3 J7200 SoCs
Hi Nishanth,
This is v2 of the R5F DT node patches, and is a minor revision of the previous series [1] with couple of patches squashed in. There is no change in overall delta. Please see the v1 cover-letter for details and the individual patches for exact delta.
regards
Suman
[1] https://patchwork.kernel.org/project/linux-arm-kernel/cover/[email protected]/
Suman Anna (3):
arm64: dts: ti: k3-j7200: Add R5F cluster nodes
arm64: dts: ti: k3-j7200-som-p0: Add mailboxes to R5Fs
arm64: dts: ti: k3-j7200-som-p0: Add DDR carveout memory nodes for
R5Fs
arch/arm64/boot/dts/ti/k3-j7200-main.dtsi | 42 +++++++++- .../boot/dts/ti/k3-j7200-mcu-wakeup.dtsi | 42 +++++++++- arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi | 80 ++++++++++++++++++- 3 files changed, 161 insertions(+), 3 deletions(-)
Signature · 1 line
2.29.2
PATCH v2 1/3 arm64: dts: ti: k3-j7200: Add R5F cluster nodes
The J7200 SoCs have 2 dual-core Arm Cortex-R5F processor (R5FSS) subsystems/clusters. One R5F cluster is present within the MCU domain (MCU_R5FSS0), and the other one is present within the MAIN domain (MAIN_R5FSS0). Each of these can be configured at boot time to be either run in a LockStep mode or in an Asymmetric Multi Processing (AMP) fashion in Split-mode. These subsystems have 64 KB each Tightly-Coupled Memory (TCM) internal memories for each core split between two banks - ATCM and BTCM (further interleaved into two banks). The TCMs of both Cores are combined in LockStep-mode to provide a larger 128 KB of memory, but otherwise are functionally similar to those on J721E SoCs.
Add the DT nodes for both the MCU and MAIN domain R5F cluster/subsystems, the two R5F cores are added as child nodes to each of the R5F cluster nodes. The clusters are configured to run in LockStep mode by default, with the ATCMs enabled to allow the R5 cores to execute code from DDR with boot-strapping code from ATCM. The inter-processor communication between the main A72 cores and these processors is achieved through shared memory and Mailboxes.
The following firmware names are used by default for these cores, and can be overridden in a board dts file if desired:
MCU R5FSS0 Core0: j7200-mcu-r5f0_0-fw (both in LockStep and Split modes) MCU R5FSS0 Core1: j7200-mcu-r5f0_1-fw (needed only in Split mode) MAIN R5FSS0 Core0: j7200-main-r5f0_0-fw (both in LockStep & Split modes) MAIN R5FSS0 Core1: j7200-main-r5f0_1-fw (needed only in Split mode)
---
v2:
- Squashed patch 2 from v1
- Updated patch title and description
v1:
https://patchwork.kernel.org/project/linux-arm-kernel/patch/[email protected]/
https://patchwork.kernel.org/project/linux-arm-kernel/patch/[email protected]/
arch/arm64/boot/dts/ti/k3-j7200-main.dtsi | 42 ++++++++++++++++++- .../boot/dts/ti/k3-j7200-mcu-wakeup.dtsi | 42 ++++++++++++++++++- 2 files changed, 82 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/ti/k3-j7200-main.dtsi +41 -1
@@ -2,7 +2,7 @@ /* * Device Tree Source for J7200 SoC Family Main Domain peripherals * - * Copyright (C) 2020 Texas Instruments Incorporated - https://www.ti.com/ + * Copyright (C) 2020-2021 Texas Instruments Incorporated - https://www.ti.com/ */ &cbass_main {
@@ -560,4 +560,44 @@ usb0: usb@6000000 { dr_mode = "otg"; }; }; + + main_r5fss0: r5fss@5c00000 { + compatible = "ti,j7200-r5fss"; + ti,cluster-mode = <1>; + #address-cells = <1>; + #size-cells = <1>; + ranges = <0x5c00000 0x00 0x5c00000 0x20000>, + <0x5d00000 0x00 0x5d00000 0x20000>; + power-domains = <&k3_pds 243 TI_SCI_PD_EXCLUSIVE>; + + main_r5fss0_core0: r5f@5c00000 { + compatible = "ti,j7200-r5f"; + reg = <0x5c00000 0x00010000>, + <0x5c10000 0x00010000>; + reg-names = "atcm", "btcm"; + ti,sci = <&dmsc>; + ti,sci-dev-id = <245>; + ti,sci-proc-ids = <0x06 0xff>; + resets = <&k3_reset 245 1>; + firmware-name = "j7200-main-r5f0_0-fw"; + ti,atcm-enable = <1>; + ti,btcm-enable = <1>; + ti,loczrama = <1>; + }; + + main_r5fss0_core1: r5f@5d00000 { + compatible = "ti,j7200-r5f"; + reg = <0x5d00000 0x00008000>, + <0x5d10000 0x00008000>; + reg-names = "atcm", "btcm"; + ti,sci = <&dmsc>; + ti,sci-dev-id = <246>; + ti,sci-proc-ids = <0x07 0xff>; + resets = <&k3_reset 246 1>; + firmware-name = "j7200-main-r5f0_1-fw"; + ti,atcm-enable = <1>; + ti,btcm-enable = <1>; + ti,loczrama = <1>; + }; + }; };
arch/arm64/boot/dts/ti/k3-j7200-mcu-wakeup.dtsi +41 -1
52 lines not on this page · raw message
Signature · 1 line
2.29.2
PATCH v2 2/3 arm64: dts: ti: k3-j7200-som-p0: Add mailboxes to R5Fs
In reply to Suman AnnaAdd the required 'mboxes' property to all the R5F processors for the TI J7200 common processor board. The mailboxes and some shared memory are required for running the Remote Processor Messaging (RPMsg) stack between the host processor and each of the R5Fs. The nodes are therefore added in the common k3-j7200-som-p0.dtsi file so that all of these can be co-located.
The chosen sub-mailboxes match the values used in the current firmware images. This can be changed, if needed, as per the system integration needs after making appropriate changes on the firmware side as well.
Note that any R5F Core1 resources are needed and used only when that R5F cluster is configured for Split-mode.
---
v2: No changes
arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-)
arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi +17 -1
@@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0 /* - * Copyright (C) 2020 Texas Instruments Incorporated - https://www.ti.com/ + * Copyright (C) 2020-2021 Texas Instruments Incorporated - https://www.ti.com/ */ /dts-v1/;
@@ -141,6 +141,22 @@ &mailbox0_cluster11 { status = "disabled"; }; +&mcu_r5fss0_core0 { + mboxes = <&mailbox0_cluster0 &mbox_mcu_r5fss0_core0>; +}; + +&mcu_r5fss0_core1 { + mboxes = <&mailbox0_cluster0 &mbox_mcu_r5fss0_core1>; +}; + +&main_r5fss0_core0 { + mboxes = <&mailbox0_cluster1 &mbox_main_r5fss0_core0>; +}; + +&main_r5fss0_core1 { + mboxes = <&mailbox0_cluster1 &mbox_main_r5fss0_core1>; +}; + &main_i2c0 { pinctrl-names = "default"; pinctrl-0 = <&main_i2c0_pins_default>;
Signature · 1 line
2.29.2
PATCH v2 3/3 arm64: dts: ti: k3-j7200-som-p0: Add DDR carveout memory nodes for R5Fs
In reply to Suman AnnaTwo carveout reserved memory nodes each have been added for each of the R5F remote processor devices within both the MCU and MAIN domains on the TI J7200 EVM boards. These nodes are assigned to the respective rproc device nodes as well. The first region will be used as the DMA pool for the rproc device, and the second region will furnish the static carveout regions for the firmware memory.
An additional reserved memory node is also added to reserve a portion of the DDR memory to be used for performing inter-processor communication between all the remote processors running RTOS. 8 MB of memory is reserved for this purpose, and this accounts for all the vrings and vring buffers between all the possible pairs of remote processors.
The current carveout addresses and sizes are defined statically for each device. The R5F processors do not have an MMU, and as such require the exact memory used by the firmwares to be set-aside. The firmware images do not require any RSC_CARVEOUT entries in their resource tables either to allocate the memory for firmware memory segments.
NOTE:
1. The R5F1 carveouts are needed only if the R5F cluster is running in Split (non-LockStep) mode. The reserved memory nodes can be disabled later on if there is no use-case defined to use the corresponding remote processor.
2. The J7200 SoCs have no DSPs and one less R5F cluster compared to J721E SoCs. So, while the carveout memories reserved for the R5F clusters present on the SoC match to those on J721E, the overall memory map reserved for firmwares is quite different.
---
v2:
- Squashed in Patch 5 from v1
- Updated patch description
v1:
https://patchwork.kernel.org/project/linux-arm-kernel/patch/[email protected]/
https://patchwork.kernel.org/project/linux-arm-kernel/patch/[email protected]/
arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi | 62 +++++++++++++++++++++ 1 file changed, 62 insertions(+)
arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi +62 -0
@@ -25,6 +25,60 @@ secure_ddr: optee@9e800000 { alignment = <0x1000>; no-map; }; + + mcu_r5fss0_core0_dma_memory_region: r5f-dma-memory@a0000000 { + compatible = "shared-dma-pool"; + reg = <0x00 0xa0000000 0x00 0x100000>; + no-map; + }; + + mcu_r5fss0_core0_memory_region: r5f-memory@a0100000 { + compatible = "shared-dma-pool"; + reg = <0x00 0xa0100000 0x00 0xf00000>; + no-map; + }; + + mcu_r5fss0_core1_dma_memory_region: r5f-dma-memory@a1000000 { + compatible = "shared-dma-pool"; + reg = <0x00 0xa1000000 0x00 0x100000>; + no-map; + }; + + mcu_r5fss0_core1_memory_region: r5f-memory@a1100000 { + compatible = "shared-dma-pool"; + reg = <0x00 0xa1100000 0x00 0xf00000>; + no-map; + }; + + main_r5fss0_core0_dma_memory_region: r5f-dma-memory@a2000000 { + compatible = "shared-dma-pool"; + reg = <0x00 0xa2000000 0x00 0x100000>; + no-map; + }; + + main_r5fss0_core0_memory_region: r5f-memory@a2100000 { + compatible = "shared-dma-pool"; + reg = <0x00 0xa2100000 0x00 0xf00000>; + no-map; + }; + + main_r5fss0_core1_dma_memory_region: r5f-dma-memory@a3000000 { + compatible = "shared-dma-pool"; + reg = <0x00 0xa3000000 0x00 0x100000>; + no-map; + }; + + main_r5fss0_core1_memory_region: r5f-memory@a3100000 { + compatible = "shared-dma-pool"; + reg = <0x00 0xa3100000 0x00 0xf00000>; + no-map; + }; + + rtos_ipc_memory_region: ipc-memories@a4000000 { + reg = <0x00 0xa4000000 0x00 0x00800000>; + alignment = <0x1000>; + no-map; + }; }; };
@@ -143,18 +197,26 @@ &mailbox0_cluster11 { &mcu_r5fss0_core0 { mboxes = <&mailbox0_cluster0 &mbox_mcu_r5fss0_core0>; + memory-region = <&mcu_r5fss0_core0_dma_memory_region>, + <&mcu_r5fss0_core0_memory_region>; }; &mcu_r5fss0_core1 { mboxes = <&mailbox0_cluster0 &mbox_mcu_r5fss0_core1>; + memory-region = <&mcu_r5fss0_core1_dma_memory_region>, + <&mcu_r5fss0_core1_memory_region>; }; &main_r5fss0_core0 { mboxes = <&mailbox0_cluster1 &mbox_main_r5fss0_core0>; + memory-region = <&main_r5fss0_core0_dma_memory_region>, + <&main_r5fss0_core0_memory_region>; }; &main_r5fss0_core1 { mboxes = <&mailbox0_cluster1 &mbox_main_r5fss0_core1>; + memory-region = <&main_r5fss0_core1_dma_memory_region>, + <&main_r5fss0_core1_memory_region>; }; &main_i2c0 {
Signature · 7 lines
2.29.2 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Quoted 6 lines · Suman Anna
Hi Nishanth,
This is v2 of the R5F DT node patches, and is a minor revision of the previous series [1] with couple of patches squashed in. There is no change in overall delta. Please see the v1 cover-letter for details and the individual patches for exact delta.
Series looks good to me.
Thanks and regards,
Lokesh
Quoted 17 lines
regards
Suman[1] https://patchwork.kernel.org/project/linux-arm-kernel/cover/[email protected]/
Suman Anna (3):
arm64: dts: ti: k3-j7200: Add R5F cluster nodes
arm64: dts: ti: k3-j7200-som-p0: Add mailboxes to R5Fs
arm64: dts: ti: k3-j7200-som-p0: Add DDR carveout memory nodes for
R5Fsarch/arm64/boot/dts/ti/k3-j7200-main.dtsi | 42 +++++++++- .../boot/dts/ti/k3-j7200-mcu-wakeup.dtsi | 42 +++++++++- arch/arm64/boot/dts/ti/k3-j7200-som-p0.dtsi | 80 ++++++++++++++++++- 3 files changed, 161 insertions(+), 3 deletions(-)
Quoted 9 lines · Suman Anna
This is v2 of the R5F DT node patches, and is a minor revision of the previous series [1] with couple of patches squashed in. There is no change in overall delta. Please see the v1 cover-letter for details and the individual patches for exact delta.
regards
Suman[...]
Hi Suman Anna,
I have applied the following to branch ti-k3-next on [1]. Thank you!
[1/3] arm64: dts: ti: k3-j7200: Add R5F cluster nodes
commit: eb6f3655d3ed4ee093b484b7a7246a61ae2bc30f
[2/3] arm64: dts: ti: k3-j7200-som-p0: Add mailboxes to R5Fs
commit: 7a3b0c2ad3b0cfac5cb8820b8961f0956ff863fb
[3/3] arm64: dts: ti: k3-j7200-som-p0: Add DDR carveout memory nodes for R5Fs
commit: c8a9c85d4e702f8c81c08f630f2f30901af5ba16All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent up the chain during the next merge window (or sooner if it is a relevant bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
[1] git://git.kernel.org/pub/scm/linux/kernel/git/nmenon/linux.git
Signature · 9 lines
Regards, Nishanth Menon Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3 1A34 DDB5 849D 1736 249D _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel