[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 16/16] hw/riscv: Use the CPU to determine if 32-bit
From: |
Richard Henderson |
Subject: |
Re: [PATCH v4 16/16] hw/riscv: Use the CPU to determine if 32-bit |
Date: |
Wed, 16 Dec 2020 12:51:17 -0600 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 |
On 12/16/20 12:23 PM, Alistair Francis wrote:
> Instead of using string compares to determine if a RISC-V machine is
> using 32-bit or 64-bit CPUs we can use the initalised CPUs. This avoids
> us having to maintain a list of CPU names to compare against.
>
> This commit also fixes the name of the function to match the
> riscv_cpu_is_32bit() function.
>
> Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
> ---
> include/hw/riscv/boot.h | 8 +++++---
> hw/riscv/boot.c | 31 ++++++++++---------------------
> hw/riscv/sifive_u.c | 10 +++++-----
> hw/riscv/spike.c | 8 ++++----
> hw/riscv/virt.c | 9 +++++----
> 5 files changed, 29 insertions(+), 37 deletions(-)
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
r~
- [PATCH v4 10/16] target/riscv: Add a riscv_cpu_is_32bit() helper function, (continued)
- [PATCH v4 10/16] target/riscv: Add a riscv_cpu_is_32bit() helper function, Alistair Francis, 2020/12/16
- [PATCH v4 11/16] target/riscv: Specify the XLEN for CPUs, Alistair Francis, 2020/12/16
- [PATCH v4 12/16] target/riscv: cpu: Remove compile time XLEN checks, Alistair Francis, 2020/12/16
- [PATCH v4 13/16] target/riscv: cpu_helper: Remove compile time XLEN checks, Alistair Francis, 2020/12/16
- [PATCH v4 14/16] target/riscv: csr: Remove compile time XLEN checks, Alistair Francis, 2020/12/16
- [PATCH v4 15/16] target/riscv: cpu: Set XLEN independently from target, Alistair Francis, 2020/12/16
- [PATCH v4 16/16] hw/riscv: Use the CPU to determine if 32-bit, Alistair Francis, 2020/12/16