Re: [PATCH v2] riscv: Add RISCVCPUConfig.satp_mode to set sv48, sv57, etc.

2022-11-28 Thread Andrew Jones
On Fri, Nov 25, 2022 at 11:59:54AM +0100, Alexandre Ghiti wrote: > RISC-V specifies multiple sizes for addressable memory and Linux probes for > the machine's support at startup via the satp CSR register (done in > csr.c:validate_vm). > > As per the specification, sv64 must support sv57, which in

Re: [PATCH v2] riscv: Add RISCVCPUConfig.satp_mode to set sv48, sv57, etc.

2022-11-27 Thread Bin Meng
On Fri, Nov 25, 2022 at 7:01 PM Alexandre Ghiti wrote: > > RISC-V specifies multiple sizes for addressable memory and Linux probes for > the machine's support at startup via the satp CSR register (done in > csr.c:validate_vm). > > As per the specification, sv64 must support sv57, which in turn mus

[PATCH v2] riscv: Add RISCVCPUConfig.satp_mode to set sv48, sv57, etc.

2022-11-25 Thread Alexandre Ghiti
RISC-V specifies multiple sizes for addressable memory and Linux probes for the machine's support at startup via the satp CSR register (done in csr.c:validate_vm). As per the specification, sv64 must support sv57, which in turn must support sv48...etc. So we can restrict machine support by simply