mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 09:43:56 -06:00
target/riscv: Move misa_mxl_max to class
misa_mxl_max is common for all instances of a RISC-V CPU class so they are better put into class. Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com> Reviewed-by: Alistair Francis <alistair.francis@wdc.com> Message-ID: <20240203-riscv-v11-2-a23f4848a628@daynix.com> Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
This commit is contained in:
parent
0e350c1ada
commit
742cc269c7
8 changed files with 112 additions and 99 deletions
|
@ -36,7 +36,8 @@
|
|||
|
||||
bool riscv_is_32bit(RISCVHartArrayState *harts)
|
||||
{
|
||||
return harts->harts[0].env.misa_mxl_max == MXL_RV32;
|
||||
RISCVCPUClass *mcc = RISCV_CPU_GET_CLASS(&harts->harts[0]);
|
||||
return mcc->misa_mxl_max == MXL_RV32;
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue