diff options
Diffstat (limited to 'arch/mips/mm')
-rw-r--r-- | arch/mips/mm/page.c | 10 | ||||
-rw-r--r-- | arch/mips/mm/tlbex.c | 3 |
2 files changed, 8 insertions, 5 deletions
diff --git a/arch/mips/mm/page.c b/arch/mips/mm/page.c index d827d6144369..cab81f42eee5 100644 --- a/arch/mips/mm/page.c +++ b/arch/mips/mm/page.c | |||
@@ -310,8 +310,8 @@ void __cpuinit build_clear_page(void) | |||
310 | if (R4600_V2_HIT_CACHEOP_WAR && cpu_is_r4600_v2_x()) | 310 | if (R4600_V2_HIT_CACHEOP_WAR && cpu_is_r4600_v2_x()) |
311 | uasm_i_lui(&buf, AT, 0xa000); | 311 | uasm_i_lui(&buf, AT, 0xa000); |
312 | 312 | ||
313 | off = min(8, pref_bias_clear_store / cache_line_size) * | 313 | off = cache_line_size ? min(8, pref_bias_clear_store / cache_line_size) |
314 | cache_line_size; | 314 | * cache_line_size : 0; |
315 | while (off) { | 315 | while (off) { |
316 | build_clear_pref(&buf, -off); | 316 | build_clear_pref(&buf, -off); |
317 | off -= cache_line_size; | 317 | off -= cache_line_size; |
@@ -454,12 +454,14 @@ void __cpuinit build_copy_page(void) | |||
454 | if (R4600_V2_HIT_CACHEOP_WAR && cpu_is_r4600_v2_x()) | 454 | if (R4600_V2_HIT_CACHEOP_WAR && cpu_is_r4600_v2_x()) |
455 | uasm_i_lui(&buf, AT, 0xa000); | 455 | uasm_i_lui(&buf, AT, 0xa000); |
456 | 456 | ||
457 | off = min(8, pref_bias_copy_load / cache_line_size) * cache_line_size; | 457 | off = cache_line_size ? min(8, pref_bias_copy_load / cache_line_size) * |
458 | cache_line_size : 0; | ||
458 | while (off) { | 459 | while (off) { |
459 | build_copy_load_pref(&buf, -off); | 460 | build_copy_load_pref(&buf, -off); |
460 | off -= cache_line_size; | 461 | off -= cache_line_size; |
461 | } | 462 | } |
462 | off = min(8, pref_bias_copy_store / cache_line_size) * cache_line_size; | 463 | off = cache_line_size ? min(8, pref_bias_copy_load / cache_line_size) * |
464 | cache_line_size : 0; | ||
463 | while (off) { | 465 | while (off) { |
464 | build_copy_store_pref(&buf, -off); | 466 | build_copy_store_pref(&buf, -off); |
465 | off -= cache_line_size; | 467 | off -= cache_line_size; |
diff --git a/arch/mips/mm/tlbex.c b/arch/mips/mm/tlbex.c index 382738ca8a0b..76da73a5ab3c 100644 --- a/arch/mips/mm/tlbex.c +++ b/arch/mips/mm/tlbex.c | |||
@@ -224,8 +224,9 @@ static u32 final_handler[64] __cpuinitdata; | |||
224 | static void __cpuinit __maybe_unused build_tlb_probe_entry(u32 **p) | 224 | static void __cpuinit __maybe_unused build_tlb_probe_entry(u32 **p) |
225 | { | 225 | { |
226 | switch (current_cpu_type()) { | 226 | switch (current_cpu_type()) { |
227 | /* Found by experiment: R4600 v2.0 needs this, too. */ | 227 | /* Found by experiment: R4600 v2.0/R4700 needs this, too. */ |
228 | case CPU_R4600: | 228 | case CPU_R4600: |
229 | case CPU_R4700: | ||
229 | case CPU_R5000: | 230 | case CPU_R5000: |
230 | case CPU_R5000A: | 231 | case CPU_R5000A: |
231 | case CPU_NEVADA: | 232 | case CPU_NEVADA: |