From: Mohamed Mediouni <[email protected]> When SME is disabled as part of the CPU configuration, do not restore SME state.
Signed-off-by: Mohamed Mediouni <[email protected]> Reviewed-by: Peter Maydell <[email protected]> Message-id: [email protected] Signed-off-by: Peter Maydell <[email protected]> --- target/arm/hvf/hvf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/arm/hvf/hvf.c b/target/arm/hvf/hvf.c index b00a7e1a845..6085ac22849 100644 --- a/target/arm/hvf/hvf.c +++ b/target/arm/hvf/hvf.c @@ -1394,7 +1394,7 @@ int hvf_arch_init_vcpu(CPUState *cpu) int i; if (__builtin_available(macOS 15.2, *)) { - if (hvf_arm_sme2_supported()) { + if (cpu_isar_feature(aa64_sme, arm_cpu)) { sregs_match_len += ARRAY_SIZE(hvf_sreg_list_sme2) + 1; } @@ -1444,7 +1444,7 @@ int hvf_arch_init_vcpu(CPUState *cpu) } } if (__builtin_available(macOS 15.2, *)) { - if (hvf_arm_sme2_supported()) { + if (cpu_isar_feature(aa64_sme, arm_cpu)) { for (i = 0; i < ARRAY_SIZE(hvf_sreg_list_sme2); i++) { hv_sys_reg_t hvf_id = hvf_sreg_list_sme2[i].sreg; uint64_t kvm_id = HVF_TO_KVMID(hvf_id); -- 2.43.0
