target/arm/hvf/hvf.c | 5 +++++ 1 file changed, 5 insertions(+)
macOS 15.2's Hypervisor.framework exposes SME feature on M4 Macs.
However, HVF does not properly support it yet causing QEMU to
fail to start when HVF accelerator is used on these systems.
Signed-off-by: Joelle van Dyne <j@getutm.app>
---
target/arm/hvf/hvf.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/target/arm/hvf/hvf.c b/target/arm/hvf/hvf.c
index 0afd96018e..261db2d227 100644
--- a/target/arm/hvf/hvf.c
+++ b/target/arm/hvf/hvf.c
@@ -899,6 +899,11 @@ static bool hvf_arm_get_host_cpu_features(ARMHostCPUFeatures *ahcf)
clamp_id_aa64mmfr0_parange_to_ipa_size(&host_isar.id_aa64mmfr0);
+ /*
+ * Disable SME which is not properly handled by QEMU yet
+ */
+ host_isar.id_aa64pfr1 &= ~R_ID_AA64PFR1_SME_MASK;
+
ahcf->isar = host_isar;
/*
--
2.41.0
On Mon, 24 Feb 2025 at 16:57, Joelle van Dyne <j@getutm.app> wrote: > > macOS 15.2's Hypervisor.framework exposes SME feature on M4 Macs. > However, HVF does not properly support it yet causing QEMU to > fail to start when HVF accelerator is used on these systems. > > Signed-off-by: Joelle van Dyne <j@getutm.app> > --- > target/arm/hvf/hvf.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/target/arm/hvf/hvf.c b/target/arm/hvf/hvf.c > index 0afd96018e..261db2d227 100644 > --- a/target/arm/hvf/hvf.c > +++ b/target/arm/hvf/hvf.c > @@ -899,6 +899,11 @@ static bool hvf_arm_get_host_cpu_features(ARMHostCPUFeatures *ahcf) > > clamp_id_aa64mmfr0_parange_to_ipa_size(&host_isar.id_aa64mmfr0); > > + /* > + * Disable SME which is not properly handled by QEMU yet > + */ > + host_isar.id_aa64pfr1 &= ~R_ID_AA64PFR1_SME_MASK; > + > ahcf->isar = host_isar; Thanks for sending in this patch; I've applied it to target-arm.next. I expanded the comment a bit to add my understanding of what pieces are missing in QEMU to support this, and threw in a cc:stable so we can get this backported to the stable release branches. -- PMM
© 2016 - 2025 Red Hat, Inc.