summaryrefslogtreecommitdiff
path: root/arch/arm/mach-at91
diff options
context:
space:
mode:
authorAdam Ford <aford173@gmail.com>2018-08-16 13:23:11 -0500
committerTom Rini <trini@konsulko.com>2018-09-10 21:19:16 -0400
commit93b283d49f933f95f3a6f40762936f454ac655a8 (patch)
tree73100f23d055bae16636df9368a8d4558e459f3a /arch/arm/mach-at91
parent5f133bb7c519ebb069f74bbda428627ad28419c6 (diff)
ARM: CPU: arm926ejs: Consolidate cache routines to common file
Four different boards had different options for enabling cache that were virtually all the same. This consolidates these common functions into arch/arm/cpu/arm926ejs/cache.c This also has the positive side-effect of enabling cache on the Davinci (da850) boards. Signed-off-by: Adam Ford <aford173@gmail.com> [trini: Add mach-at91 to the list of consolidations] Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'arch/arm/mach-at91')
-rw-r--r--arch/arm/mach-at91/arm926ejs/Makefile1
-rw-r--r--arch/arm/mach-at91/arm926ejs/cache.c28
2 files changed, 0 insertions, 29 deletions
diff --git a/arch/arm/mach-at91/arm926ejs/Makefile b/arch/arm/mach-at91/arm926ejs/Makefile
index a8a49ca43f1..0639d7ea1e7 100644
--- a/arch/arm/mach-at91/arm926ejs/Makefile
+++ b/arch/arm/mach-at91/arm926ejs/Makefile
@@ -16,7 +16,6 @@ obj-$(CONFIG_AT91SAM9N12) += at91sam9n12_devices.o
obj-$(CONFIG_AT91SAM9X5) += at91sam9x5_devices.o
obj-$(CONFIG_AT91_EFLASH) += eflash.o
obj-$(CONFIG_AT91_LED) += led.o
-obj-y += cache.o
obj-y += clock.o
obj-y += cpu.o
obj-y += reset.o
diff --git a/arch/arm/mach-at91/arm926ejs/cache.c b/arch/arm/mach-at91/arm926ejs/cache.c
deleted file mode 100644
index 024c8f5f3e9..00000000000
--- a/arch/arm/mach-at91/arm926ejs/cache.c
+++ /dev/null
@@ -1,28 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0+
-/*
- * (C) Copyright 2016
- * Heiko Schocher, DENX Software Engineering, hs@denx.de.
- */
-#include <linux/types.h>
-#include <common.h>
-
-void enable_caches(void)
-{
-#ifndef CONFIG_SYS_ICACHE_OFF
- icache_enable();
-#endif
-}
-
-#ifndef CONFIG_SYS_ICACHE_OFF
-/* Invalidate entire I-cache and branch predictor array */
-void invalidate_icache_all(void)
-{
- unsigned long i = 0;
-
- asm ("mcr p15, 0, %0, c7, c5, 0" : : "r" (i));
-}
-#else
-void invalidate_icache_all(void)
-{
-}
-#endif