Commit 54e8d9f0 authored by Paul Burton's avatar Paul Burton

MIPS: tlbex: Simplify r3k check

We already know whether a CPU has r3k style exceptions, including TLB
exceptions, by checking cpu_has_3kex. Remove the list of CPU types in
build_tlb_refill_handler() & check cpu_has_3kex instead.
Signed-off-by: default avatarPaul Burton <paul.burton@mips.com>
Cc: linux-mips@vger.kernel.org
parent 54746829
...@@ -2607,14 +2607,7 @@ void build_tlb_refill_handler(void) ...@@ -2607,14 +2607,7 @@ void build_tlb_refill_handler(void)
check_for_high_segbits = current_cpu_data.vmbits > (PGDIR_SHIFT + PGD_ORDER + PAGE_SHIFT - 3); check_for_high_segbits = current_cpu_data.vmbits > (PGDIR_SHIFT + PGD_ORDER + PAGE_SHIFT - 3);
#endif #endif
switch (current_cpu_type()) { if (cpu_has_3kex) {
case CPU_R2000:
case CPU_R3000:
case CPU_R3000A:
case CPU_R3081E:
case CPU_TX3912:
case CPU_TX3922:
case CPU_TX3927:
#ifndef CONFIG_MIPS_PGD_C0_CONTEXT #ifndef CONFIG_MIPS_PGD_C0_CONTEXT
if (cpu_has_local_ebase) if (cpu_has_local_ebase)
build_r3000_tlb_refill_handler(); build_r3000_tlb_refill_handler();
...@@ -2631,9 +2624,9 @@ void build_tlb_refill_handler(void) ...@@ -2631,9 +2624,9 @@ void build_tlb_refill_handler(void)
#else #else
panic("No R3000 TLB refill handler"); panic("No R3000 TLB refill handler");
#endif #endif
break; return;
}
default:
if (cpu_has_ldpte) if (cpu_has_ldpte)
setup_pw(); setup_pw();
...@@ -2656,5 +2649,4 @@ void build_tlb_refill_handler(void) ...@@ -2656,5 +2649,4 @@ void build_tlb_refill_handler(void)
config_xpa_params(); config_xpa_params();
if (cpu_has_htw) if (cpu_has_htw)
config_htw_params(); config_htw_params();
}
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment