target/openrisc: Fix cpu_mmu_index
commitb9bed1b9ab37a6ae62e88a52cbcbd2ad81aa1056
authorRichard Henderson <richard.henderson@linaro.org>
Wed, 23 May 2018 02:51:00 +0000 (22 19:51 -0700)
committerStafford Horne <shorne@gmail.com>
Mon, 2 Jul 2018 15:05:28 +0000 (3 00:05 +0900)
tree15dba503a0704eca2b64bf8b77e7621bcd3208b5
parentfffde6695f4be3cf484f068f24e894280d7360ea
target/openrisc: Fix cpu_mmu_index

The code in cpu_mmu_index does not properly honor SR_DME.
This bug has workarounds elsewhere in that we flush the
tlb more often than necessary, on the state changes that
should be reflected in a change of mmu_index.

Fixing this means that we can respect the mmu_index that
is given to tlb_flush.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Stafford Horne <shorne@gmail.com>
target/openrisc/cpu.h
target/openrisc/interrupt.c
target/openrisc/interrupt_helper.c
target/openrisc/mmu.c
target/openrisc/sys_helper.c
target/openrisc/translate.c