Re: [PATCH v1 1/5] target/riscv: Add a virtualised MMU Mode

2020-10-23 Thread Alistair Francis
On Fri, Oct 23, 2020 at 12:13 PM Richard Henderson wrote: > > On 10/23/20 8:26 AM, Alistair Francis wrote: > > +++ b/target/riscv/cpu-param.h > > @@ -18,6 +18,6 @@ > > # define TARGET_VIRT_ADDR_SPACE_BITS 32 /* sv32 */ > > #endif > > #define TARGET_PAGE_BITS 12 /* 4 KiB Pages */ > > -#define NB

Re: [PATCH v1 1/5] target/riscv: Add a virtualised MMU Mode

2020-10-23 Thread Richard Henderson
On 10/23/20 8:26 AM, Alistair Francis wrote: > +++ b/target/riscv/cpu-param.h > @@ -18,6 +18,6 @@ > # define TARGET_VIRT_ADDR_SPACE_BITS 32 /* sv32 */ > #endif > #define TARGET_PAGE_BITS 12 /* 4 KiB Pages */ > -#define NB_MMU_MODES 4 > +#define NB_MMU_MODES 8 Is there really a PRV_M + virt enab

[PATCH v1 1/5] target/riscv: Add a virtualised MMU Mode

2020-10-23 Thread Alistair Francis
Add a new MMU mode that includes the current virt mode. Signed-off-by: Alistair Francis --- target/riscv/cpu-param.h | 2 +- target/riscv/cpu.h| 4 +++- target/riscv/cpu_helper.c | 6 +- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/target/riscv/cpu-param.h b/target