aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-s5pv310/cpu.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-s5pv310/cpu.c')
-rw-r--r--arch/arm/mach-s5pv310/cpu.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/arch/arm/mach-s5pv310/cpu.c b/arch/arm/mach-s5pv310/cpu.c
index 5b979005442..4e3f5be264e 100644
--- a/arch/arm/mach-s5pv310/cpu.c
+++ b/arch/arm/mach-s5pv310/cpu.c
@@ -15,6 +15,7 @@
15#include <asm/mach/irq.h> 15#include <asm/mach/irq.h>
16 16
17#include <asm/proc-fns.h> 17#include <asm/proc-fns.h>
18#include <asm/hardware/cache-l2x0.h>
18 19
19#include <plat/cpu.h> 20#include <plat/cpu.h>
20#include <plat/clock.h> 21#include <plat/clock.h>
@@ -148,6 +149,28 @@ static int __init s5pv310_core_init(void)
148 149
149core_initcall(s5pv310_core_init); 150core_initcall(s5pv310_core_init);
150 151
152#ifdef CONFIG_CACHE_L2X0
153static int __init s5pv310_l2x0_cache_init(void)
154{
155 /* TAG, Data Latency Control: 2cycle */
156 __raw_writel(0x110, S5P_VA_L2CC + L2X0_TAG_LATENCY_CTRL);
157 __raw_writel(0x110, S5P_VA_L2CC + L2X0_DATA_LATENCY_CTRL);
158
159 /* L2X0 Prefetch Control */
160 __raw_writel(0x30000007, S5P_VA_L2CC + L2X0_PREFETCH_CTRL);
161
162 /* L2X0 Power Control */
163 __raw_writel(L2X0_DYNAMIC_CLK_GATING_EN | L2X0_STNDBY_MODE_EN,
164 S5P_VA_L2CC + L2X0_POWER_CTRL);
165
166 l2x0_init(S5P_VA_L2CC, 0x7C070001, 0xC200ffff);
167
168 return 0;
169}
170
171early_initcall(s5pv310_l2x0_cache_init);
172#endif
173
151int __init s5pv310_init(void) 174int __init s5pv310_init(void)
152{ 175{
153 printk(KERN_INFO "S5PV310: Initializing architecture\n"); 176 printk(KERN_INFO "S5PV310: Initializing architecture\n");