aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/mm/cache-sh4.c
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2009-11-08 20:55:36 -0500
committerPaul Mundt <lethal@linux-sh.org>2009-11-08 20:55:36 -0500
commit76d2318020bf0c0c497af986a25977196715a1b9 (patch)
tree25df17084b76eba7420c3fe9e6690ea5270e7dfd /arch/sh/mm/cache-sh4.c
parente9c4148fd4f03008ecbe3b673e25764232a15503 (diff)
parent969e46a8533a3e40ce2146f6764a963b1f5505da (diff)
Merge branch 'sh/stable-updates'
Diffstat (limited to 'arch/sh/mm/cache-sh4.c')
-rw-r--r--arch/sh/mm/cache-sh4.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/sh/mm/cache-sh4.c b/arch/sh/mm/cache-sh4.c
index b5abe949c6ed..6bfd08d5fb81 100644
--- a/arch/sh/mm/cache-sh4.c
+++ b/arch/sh/mm/cache-sh4.c
@@ -65,6 +65,7 @@ static void __uses_jump_to_uncached sh4_flush_icache_range(void *args)
65 65
66 for (v = start; v < end; v += L1_CACHE_BYTES) { 66 for (v = start; v < end; v += L1_CACHE_BYTES) {
67 unsigned long icacheaddr; 67 unsigned long icacheaddr;
68 int j, n;
68 69
69 __ocbwb(v); 70 __ocbwb(v);
70 71
@@ -72,8 +73,10 @@ static void __uses_jump_to_uncached sh4_flush_icache_range(void *args)
72 cpu_data->icache.entry_mask); 73 cpu_data->icache.entry_mask);
73 74
74 /* Clear i-cache line valid-bit */ 75 /* Clear i-cache line valid-bit */
76 n = boot_cpu_data.icache.n_aliases;
75 for (i = 0; i < cpu_data->icache.ways; i++) { 77 for (i = 0; i < cpu_data->icache.ways; i++) {
76 __raw_writel(0, icacheaddr); 78 for (j = 0; j < n; j++)
79 __raw_writel(0, icacheaddr + (j * PAGE_SIZE));
77 icacheaddr += cpu_data->icache.way_incr; 80 icacheaddr += cpu_data->icache.way_incr;
78 } 81 }
79 } 82 }