[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 10/15] target/riscv: Add a riscv_cpu_is_32bit() helper fun
From: |
Alistair Francis |
Subject: |
Re: [PATCH v2 10/15] target/riscv: Add a riscv_cpu_is_32bit() helper function |
Date: |
Wed, 9 Dec 2020 14:26:01 -0800 |
On Wed, Dec 9, 2020 at 7:59 AM Richard Henderson
<richard.henderson@linaro.org> wrote:
>
> On 12/8/20 4:56 PM, Alistair Francis wrote:
> > +bool riscv_cpu_is_32bit(CPURISCVState *env)
> > +{
> > + if (env->misa & RV64) {
> > + return false;
> > + }
> > +
> > + return true;
>
> Is this ever going to more than
>
> return !(env->misa & RV64);
Eventually this could also depend on mstatus, to allow a 32-bit kernel
to run on a 64-bit firmware.
It will also hopefully one day be configurable by hypervisors.
Alistair
>
> ?
>
>
> r~
- Re: [PATCH v2 05/15] hw/riscv: boot: Remove compile time XLEN checks, (continued)
- [PATCH v2 06/15] hw/riscv: virt: Remove compile time XLEN checks, Alistair Francis, 2020/12/08
- [PATCH v2 07/15] hw/riscv: spike: Remove compile time XLEN checks, Alistair Francis, 2020/12/08
- [PATCH v2 09/15] target/riscv: fpu_helper: Match function defs in HELPER macros, Alistair Francis, 2020/12/08
- [PATCH v2 08/15] hw/riscv: sifive_u: Remove compile time XLEN checks, Alistair Francis, 2020/12/08
- [PATCH v2 10/15] target/riscv: Add a riscv_cpu_is_32bit() helper function, Alistair Francis, 2020/12/08
- [PATCH v2 11/15] target/riscv: Specify the XLEN for CPUs, Alistair Francis, 2020/12/08
- [PATCH v2 12/15] target/riscv: cpu: Remove compile time XLEN checks, Alistair Francis, 2020/12/08
- [PATCH v2 13/15] target/riscv: cpu_helper: Remove compile time XLEN checks, Alistair Francis, 2020/12/08
- [PATCH v2 14/15] target/riscv: csr: Remove compile time XLEN checks, Alistair Francis, 2020/12/08