remoteproc: k3-r5: Adjust TCM sizes in Split-mode on J7200 SoCs
authorSuman Anna <s-anna@ti.com>
Thu, 19 Nov 2020 01:05:31 +0000 (19:05 -0600)
committerBjorn Andersson <bjorn.andersson@linaro.org>
Thu, 26 Nov 2020 05:05:25 +0000 (23:05 -0600)
commitc3c21b356505e2f4c528d22903531f7764e18998
tree5160bf75cf5d559c7d50a48c1300a3cd8b858c72
parent7508ea19b20da80fcdde05354c35e2c45e875b5c
remoteproc: k3-r5: Adjust TCM sizes in Split-mode on J7200 SoCs

The J7200 SoCs have a revised R5FSS IP that adds a unique feature w.r.t
TCM sizing. Each R5F core in a cluster typically has 32 KB each of ATCM
and BTCM, with only the Core0 TCMs usable in LockStep mode. This revised
IP however doubles the total available TCM in LockStep mode by making the
Core1 TCM visible immediately after the corresponding Core0 TCM.

The R5F DT nodes on the J7200 SoCs define double (64 KB) the normal TCM
size (32 KB) for R5F Core0 for each of ATCM and BTCM to represent the
above. This increased TCM memory is only usable in LockStep-mode, and
has to be adjusted to the normal 32 KB size in Split mode. Enhance the
TI K3 R5F remoteproc for this logic through a new function. The adjustment
is a no-op on prior SoCs and relies on the correct DTS node sizes in
LockStep-mode on applicable SoCs.

Reviewed-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: Suman Anna <s-anna@ti.com>
Link: https://lore.kernel.org/r/20201119010531.21083-4-s-anna@ti.com
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
drivers/remoteproc/ti_k3_r5_remoteproc.c