@samitouri / QOSamiQemu / commits / 8dbb04a68f

hw/cpu: Build a15mpcore.c once as common object

a15mpcore.c doesn't need to include the target-specific 'kvm_arm.h' header, it only lacks the qemu_get_cpu() declaration which comes from 'hw/core/cpu.h'. Include the latter and build as common object. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20260225034451.41338-1-philmd@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

Philippe Mathieu-Daudé committed Feb 26, 2026 at 11:27 UTC 8dbb04a68fc8f484e4fc34db260529b1b8ee1c16
2 files changed +2 -2
hw/cpu/a15mpcore.c
+1 -1
@@ -22,10 +22,10 @@
22 #include "qapi/error.h"
23 #include "qemu/module.h"
24 #include "hw/cpu/a15mpcore.h"
25 +#include "hw/core/cpu.h"
26 #include "hw/core/irq.h"
27 #include "hw/core/qdev-properties.h"
28 #include "system/kvm.h"
28 -#include "kvm_arm.h"
29 #include "target/arm/gtimer.h"
30
31 static void a15mp_priv_set_irq(void *opaque, int irq, int level)
hw/cpu/meson.build
+1 -1
@@ -4,4 +4,4 @@ system_ss.add(when: 'CONFIG_CPU_CLUSTER', if_true: files('cluster.c'))
4 system_ss.add(when: 'CONFIG_ARM11MPCORE', if_true: files('arm11mpcore.c'))
5 system_ss.add(when: 'CONFIG_REALVIEW', if_true: files('realview_mpcore.c'))
6 system_ss.add(when: 'CONFIG_A9MPCORE', if_true: files('a9mpcore.c'))
7 -specific_ss.add(when: 'CONFIG_A15MPCORE', if_true: files('a15mpcore.c'))
7 +system_ss.add(when: 'CONFIG_A15MPCORE', if_true: files('a15mpcore.c'))