diff mbox series

[07/13] target/arm/cpu: remove CONFIG_KVM from arm_cpu_kvm_set_irq

Message ID 20250429050010.971128-8-pierrick.bouvier@linaro.org
State New
Headers show
Series single-binary: compile target/arm twice | expand

Commit Message

Pierrick Bouvier April 29, 2025, 5 a.m. UTC
This function is called only under kvm_enabled(), so this is safe.
Previous commit took care to add kvm_arm_set_irq stub if needed.

We need to keep a CONFIG_KVM_IS_POSSIBLE guard because
this function uses KVM_ARM_IRQ_CPU_IRQ, KVM_ARM_IRQ_CPU_FIQ and
KVM_ARM_IRQ_TYPE_CPU which are only available in this context.

Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
---
 target/arm/cpu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/target/arm/cpu.c b/target/arm/cpu.c
index 5e951675c60..e7a15ade8b4 100644
--- a/target/arm/cpu.c
+++ b/target/arm/cpu.c
@@ -1101,7 +1101,7 @@  static void arm_cpu_set_irq(void *opaque, int irq, int level)
 
 static void arm_cpu_kvm_set_irq(void *opaque, int irq, int level)
 {
-#ifdef CONFIG_KVM
+#ifdef CONFIG_KVM_IS_POSSIBLE
     ARMCPU *cpu = opaque;
     CPUARMState *env = &cpu->env;
     CPUState *cs = CPU(cpu);