]> git.baikalelectronics.ru Git - uboot.git/commit
arm: mach-k3: security: Clean image out of cache before authentication
authorAndrew F. Davis <afd@ti.com>
Tue, 7 Jan 2020 23:22:29 +0000 (18:22 -0500)
committerLokesh Vutla <lokeshvutla@ti.com>
Mon, 20 Jan 2020 04:40:28 +0000 (10:10 +0530)
commit7fcb00b959efed66599700d2861ec81216489285
treee0593dd214373c9aa7b9f2809bed410c8627c4ad
parent2647b3326fde85dbf901fb67bee60bbb0700d414
arm: mach-k3: security: Clean image out of cache before authentication

On K3 systems U-Boot runs on both an R5 and a large ARM cores (usually
A53 or A72). The large ARMs are coherent with the DMA controllers and
the SYSFW that perform authentication. And previously the R5 core did
not enable caches. Now that R5 does enable caching we need to be sure
to clean out any of the image that may still only be in cache before we
read it using external DMA for authentication.

Although not expected to happen, it may be possible that the data was
read back into cache after the flush but before the external operation,
in this case we must invalidate our stale local cached version.

Signed-off-by: Andrew F. Davis <afd@ti.com>
Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
arch/arm/mach-k3/security.c