ARM: introduce sync_caches_for_execution
We have several places in the code which which prepares just modified code
for execution. This is done differently in all the places, so add a common
function to be used by all.

Most places called arm_early_mmu_cache_flush(). This function includes
invalidating the instruction cache, so doing it again is unnecessary.

Sometimes we had arm_early_mmu_cache_flush() inside #ifdef CONFIG_MMU.
The ifdef seems unnecessary since we do not have it consistently, so
remove the ifdef.

Some early i.MX xload code had icache_invalidate() but forgot to flush
the caches. Replace the instruction cache invalidation with
sync_caches_for_execution().

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent b0a89d8 commit c5c08624f73a0b7e8f822127b256b19ff1b6f553
@Sascha Hauer Sascha Hauer authored on 13 May 2019
Showing 8 changed files
View
arch/arm/cpu/common.c
View
arch/arm/cpu/setupc.S
View
arch/arm/cpu/setupc_64.S
View
arch/arm/cpu/start-pbl.c
View
arch/arm/cpu/uncompress.c
View
arch/arm/include/asm/cache.h
View
arch/arm/mach-layerscape/xload-qspi.c
View
drivers/mci/imx-esdhc-pbl.c