diff options
-rw-r--r-- | arch/arm/mm/cache-v6.S | 1 | ||||
-rw-r--r-- | arch/arm/mm/cache-v7.S | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/arch/arm/mm/cache-v6.S b/arch/arm/mm/cache-v6.S index c96fa1b3f49f..73b4a8b66a57 100644 --- a/arch/arm/mm/cache-v6.S +++ b/arch/arm/mm/cache-v6.S | |||
@@ -176,6 +176,7 @@ ENDPROC(v6_coherent_kern_range) | |||
176 | */ | 176 | */ |
177 | ENTRY(v6_flush_kern_dcache_area) | 177 | ENTRY(v6_flush_kern_dcache_area) |
178 | add r1, r0, r1 | 178 | add r1, r0, r1 |
179 | bic r0, r0, #D_CACHE_LINE_SIZE - 1 | ||
179 | 1: | 180 | 1: |
180 | #ifdef HARVARD_CACHE | 181 | #ifdef HARVARD_CACHE |
181 | mcr p15, 0, r0, c7, c14, 1 @ clean & invalidate D line | 182 | mcr p15, 0, r0, c7, c14, 1 @ clean & invalidate D line |
diff --git a/arch/arm/mm/cache-v7.S b/arch/arm/mm/cache-v7.S index dc18d81ef8ce..d32f02b61866 100644 --- a/arch/arm/mm/cache-v7.S +++ b/arch/arm/mm/cache-v7.S | |||
@@ -221,6 +221,8 @@ ENDPROC(v7_coherent_user_range) | |||
221 | ENTRY(v7_flush_kern_dcache_area) | 221 | ENTRY(v7_flush_kern_dcache_area) |
222 | dcache_line_size r2, r3 | 222 | dcache_line_size r2, r3 |
223 | add r1, r0, r1 | 223 | add r1, r0, r1 |
224 | sub r3, r2, #1 | ||
225 | bic r0, r0, r3 | ||
224 | 1: | 226 | 1: |
225 | mcr p15, 0, r0, c7, c14, 1 @ clean & invalidate D line / unified line | 227 | mcr p15, 0, r0, c7, c14, 1 @ clean & invalidate D line / unified line |
226 | add r0, r0, r2 | 228 | add r0, r0, r2 |