summaryrefslogtreecommitdiff
path: root/arch/arm/mach-mvebu/armada-370-xp.c
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>2013-04-09 23:26:14 +0200
committerJason Cooper <jason@lakedaemon.net>2013-04-15 19:34:16 +0000
commite33369cbf346a41daab7d2eaf23c7e5bb76ef67c (patch)
tree062671b6874e09b028079d8f8aca3763d555403a /arch/arm/mach-mvebu/armada-370-xp.c
parent31880c37c11e28cb81c70757e38392b42e695dc6 (diff)
ARM: mvebu: move L2 cache initialization in init_early()
In preparation for moving the IRQ controller driver to drivers/irqchip/, we don't want the IRQ controller driver to be responsible for initializing the L2 cache. Instead, let's initialize the L2 cache at the init_early() level, like mach-exynos/common.c is doing. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Tested-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com> Signed-off-by: Jason Cooper <jason@lakedaemon.net>
Diffstat (limited to 'arch/arm/mach-mvebu/armada-370-xp.c')
-rw-r--r--arch/arm/mach-mvebu/armada-370-xp.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
index a5ea616d6d12..c1bbfa74e646 100644
--- a/arch/arm/mach-mvebu/armada-370-xp.c
+++ b/arch/arm/mach-mvebu/armada-370-xp.c
@@ -19,6 +19,7 @@
#include <linux/time-armada-370-xp.h>
#include <linux/clk/mvebu.h>
#include <linux/dma-mapping.h>
+#include <asm/hardware/cache-l2x0.h>
#include <asm/mach/arch.h>
#include <asm/mach/map.h>
#include <asm/mach/time.h>
@@ -54,6 +55,10 @@ void __init armada_370_xp_init_early(void)
* to make sure such the allocations won't fail.
*/
init_dma_coherent_pool_size(SZ_1M);
+
+#ifdef CONFIG_CACHE_L2X0
+ l2x0_of_init(0, ~0UL);
+#endif
}
static void __init armada_370_xp_dt_init(void)