mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 15:53:54 -06:00
target/riscv: Require either I or E base extension
Signed-off-by: Alistair Francis <alistair.francis@wdc.com> Reviewed-by: Palmer Dabbelt <palmer@sifive.com> Signed-off-by: Palmer Dabbelt <palmer@sifive.com>
This commit is contained in:
parent
a101b643c2
commit
bdddd44635
1 changed files with 6 additions and 0 deletions
|
@ -373,6 +373,12 @@ static void riscv_cpu_realize(DeviceState *dev, Error **errp)
|
|||
return;
|
||||
}
|
||||
|
||||
if (!cpu->cfg.ext_i && !cpu->cfg.ext_e) {
|
||||
error_setg(errp,
|
||||
"Either I or E extension must be set");
|
||||
return;
|
||||
}
|
||||
|
||||
if (cpu->cfg.ext_g && !(cpu->cfg.ext_i & cpu->cfg.ext_m &
|
||||
cpu->cfg.ext_a & cpu->cfg.ext_f &
|
||||
cpu->cfg.ext_d)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue