target/riscv: Introduce mmuidx_priv
authorRichard Henderson <richard.henderson@linaro.org>
Wed, 12 Apr 2023 11:43:21 +0000 (13:43 +0200)
committerAlistair Francis <alistair.francis@wdc.com>
Fri, 5 May 2023 00:49:50 +0000 (10:49 +1000)
commit340b5805dbf42c0cb26eaa64d069bf3b43ee4f55
tree1a7bc9be591bcf1ff71cdc44e0a94eae34aa6558
parent4005a799f190e8c07afa45c88b1b45a9df00ee92
target/riscv: Introduce mmuidx_priv

Use the priv level encoded into the mmu_idx, rather than
starting from env->priv.  We have already checked MPRV+MPP
in riscv_cpu_mmu_index -- no need to repeat that.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Weiwei Li <liweiwei@iscas.ac.cn>
Tested-by: Daniel Henrique Barboza <dbarboza@ventanamicro.com>
Message-Id: <20230325105429.1142530-14-richard.henderson@linaro.org>
Message-Id: <20230412114333.118895-14-richard.henderson@linaro.org>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
target/riscv/cpu_helper.c
target/riscv/internals.h