diff options
| author | Peter Maydell <peter.maydell@linaro.org> | 2024-01-09 14:43:51 +0000 |
|---|---|---|
| committer | Peter Maydell <peter.maydell@linaro.org> | 2024-01-09 14:43:51 +0000 |
| commit | 1274a47fbd9739b628835936dbefa0294d9dd32c (patch) | |
| tree | 4eabfe6fbe2a11fe67a9622f4bc07e96dc12de44 /target/arm/cpu.c | |
| parent | dea9104a4f85388a1419701a18eb33c354f5658f (diff) | |
| download | focaccia-qemu-1274a47fbd9739b628835936dbefa0294d9dd32c.tar.gz focaccia-qemu-1274a47fbd9739b628835936dbefa0294d9dd32c.zip | |
target/arm: Add FEAT_NV to max, neoverse-n2, neoverse-v1 CPUs
Enable FEAT_NV on the 'max' CPU, and stop filtering it out for the Neoverse N2 and Neoverse V1 CPUs. We continue to downgrade FEAT_NV2 support to FEAT_NV for the latter two CPU types. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Tested-by: Miguel Luis <miguel.luis@oracle.com>
Diffstat (limited to 'target/arm/cpu.c')
| -rw-r--r-- | target/arm/cpu.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/target/arm/cpu.c b/target/arm/cpu.c index 1c8b787482..c15ad52ab3 100644 --- a/target/arm/cpu.c +++ b/target/arm/cpu.c @@ -2238,9 +2238,11 @@ static void arm_cpu_realizefn(DeviceState *dev, Error **errp) /* FEAT_MPAM (Memory Partitioning and Monitoring Extension) */ cpu->isar.id_aa64pfr0 = FIELD_DP64(cpu->isar.id_aa64pfr0, ID_AA64PFR0, MPAM, 0); - /* FEAT_NV (Nested Virtualization) */ - cpu->isar.id_aa64mmfr2 = - FIELD_DP64(cpu->isar.id_aa64mmfr2, ID_AA64MMFR2, NV, 0); + /* FEAT_NV2 (Enhanced Nested Virtualization support) */ + if (FIELD_EX64(cpu->isar.id_aa64mmfr2, ID_AA64MMFR2, NV) > 1) { + cpu->isar.id_aa64mmfr2 = + FIELD_DP64(cpu->isar.id_aa64mmfr2, ID_AA64MMFR2, NV, 1); + } } /* MPU can be configured out of a PMSA CPU either by setting has-mpu |