aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-mx3
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-mx3')
-rw-r--r--arch/arm/mach-mx3/mm.c27
1 files changed, 26 insertions, 1 deletions
diff --git a/arch/arm/mach-mx3/mm.c b/arch/arm/mach-mx3/mm.c
index 0589b5cd33c7..44fcb6679f9a 100644
--- a/arch/arm/mach-mx3/mm.c
+++ b/arch/arm/mach-mx3/mm.c
@@ -22,10 +22,14 @@
22 22
23#include <linux/mm.h> 23#include <linux/mm.h>
24#include <linux/init.h> 24#include <linux/init.h>
25#include <mach/hardware.h> 25#include <linux/err.h>
26
26#include <asm/pgtable.h> 27#include <asm/pgtable.h>
27#include <asm/mach/map.h> 28#include <asm/mach/map.h>
29#include <asm/hardware/cache-l2x0.h>
30
28#include <mach/common.h> 31#include <mach/common.h>
32#include <mach/hardware.h>
29 33
30/*! 34/*!
31 * @file mm.c 35 * @file mm.c
@@ -62,3 +66,24 @@ void __init mxc_map_io(void)
62{ 66{
63 iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); 67 iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc));
64} 68}
69
70#ifdef CONFIG_CACHE_L2X0
71static int mxc_init_l2x0(void)
72{
73 void __iomem *l2x0_base;
74
75 l2x0_base = ioremap(L2CC_BASE_ADDR, 4096);
76 if (IS_ERR(l2x0_base)) {
77 printk(KERN_ERR "remapping L2 cache area failed with %ld\n",
78 PTR_ERR(l2x0_base));
79 return 0;
80 }
81
82 l2x0_init(l2x0_base, 0x00030024, 0x00000000);
83
84 return 0;
85}
86
87arch_initcall(mxc_init_l2x0);
88#endif
89