diff options
| author | Richard Henderson <richard.henderson@linaro.org> | 2022-06-20 10:52:01 -0700 |
|---|---|---|
| committer | Peter Maydell <peter.maydell@linaro.org> | 2022-06-27 11:18:17 +0100 |
| commit | e74c097638d38b46d9c68f11565432034afc0ad0 (patch) | |
| tree | 8f885e504469e1bc251308e66fb0592c4d395868 /target/arm/cpu.c | |
| parent | 70cc9ee19e53bc8bc597c5134e294a2ab377c4da (diff) | |
| download | focaccia-qemu-e74c097638d38b46d9c68f11565432034afc0ad0.tar.gz focaccia-qemu-e74c097638d38b46d9c68f11565432034afc0ad0.zip | |
target/arm: Add cpu properties for SME
Mirror the properties for SVE. The main difference is that any arbitrary set of powers of 2 may be supported, and not the stricter constraints that apply to SVE. Include a property to control FEAT_SME_FA64, as failing to restrict the runtime to the proper subset of insns could be a major point for bugs. Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 20220620175235.60881-18-richard.henderson@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target/arm/cpu.c')
| -rw-r--r-- | target/arm/cpu.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/target/arm/cpu.c b/target/arm/cpu.c index 660fd8b8b9..bb44ad45aa 100644 --- a/target/arm/cpu.c +++ b/target/arm/cpu.c @@ -1123,11 +1123,13 @@ static void arm_cpu_initfn(Object *obj) #ifdef CONFIG_USER_ONLY # ifdef TARGET_AARCH64 /* - * The linux kernel defaults to 512-bit vectors, when sve is supported. - * See documentation for /proc/sys/abi/sve_default_vector_length, and - * our corresponding sve-default-vector-length cpu property. + * The linux kernel defaults to 512-bit for SVE, and 256-bit for SME. + * These values were chosen to fit within the default signal frame. + * See documentation for /proc/sys/abi/{sve,sme}_default_vector_length, + * and our corresponding cpu property. */ cpu->sve_default_vq = 4; + cpu->sme_default_vq = 2; # endif #else /* Our inbound IRQ and FIQ lines */ @@ -1430,6 +1432,12 @@ void arm_cpu_finalize_features(ARMCPU *cpu, Error **errp) return; } + arm_cpu_sme_finalize(cpu, &local_err); + if (local_err != NULL) { + error_propagate(errp, local_err); + return; + } + arm_cpu_pauth_finalize(cpu, &local_err); if (local_err != NULL) { error_propagate(errp, local_err); |