mirror of
https://github.com/qemu/qemu.git
synced 2025-01-09 23:23:40 +08:00
target/riscv: Add cfg properties for Zvks[c|g] extensions
Vector crypto spec defines the ShangMi algorithm suite related extensions (Zvks, Zvksc, Zvksg) combined by several vector crypto extensions. Signed-off-by: Max Chou <max.chou@sifive.com> Acked-by: Alistair Francis <alistair.francis@wdc.com> Reviewed-by: Daniel Henrique Barboza <dbarboza@ventanamicro.com> Message-ID: <20231026151828.754279-9-max.chou@sifive.com> Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
This commit is contained in:
parent
23aaefb9c9
commit
8f913d1004
@ -101,6 +101,9 @@ struct RISCVCPUConfig {
|
||||
bool ext_zvkn;
|
||||
bool ext_zvknc;
|
||||
bool ext_zvkng;
|
||||
bool ext_zvks;
|
||||
bool ext_zvksc;
|
||||
bool ext_zvksg;
|
||||
bool ext_zmmul;
|
||||
bool ext_zvfbfmin;
|
||||
bool ext_zvfbfwma;
|
||||
|
@ -519,6 +519,23 @@ void riscv_cpu_validate_set_extensions(RISCVCPU *cpu, Error **errp)
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvkt), true);
|
||||
}
|
||||
|
||||
if (cpu->cfg.ext_zvksc) {
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvks), true);
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvbc), true);
|
||||
}
|
||||
|
||||
if (cpu->cfg.ext_zvksg) {
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvks), true);
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvkg), true);
|
||||
}
|
||||
|
||||
if (cpu->cfg.ext_zvks) {
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvksed), true);
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvksh), true);
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvkb), true);
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvkt), true);
|
||||
}
|
||||
|
||||
if (cpu->cfg.ext_zvkt) {
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvbb), true);
|
||||
cpu_cfg_ext_auto_update(cpu, CPU_CFG_OFFSET(ext_zvbc), true);
|
||||
|
Loading…
Reference in New Issue
Block a user