Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit aefd18f0 authored by Chris Lalancette's avatar Chris Lalancette Committed by Avi Kivity
Browse files

KVM: x86: In DM_LOWEST, only deliver interrupts to vcpus with enabled LAPIC's



Otherwise we might try to deliver a timer interrupt to a cpu that
can't possibly handle it.

Signed-off-by: default avatarChris Lalancette <clalance@redhat.com>
Signed-off-by: default avatarMarcelo Tosatti <mtosatti@redhat.com>
parent e7dca5c0
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -100,7 +100,7 @@ int kvm_irq_delivery_to_apic(struct kvm *kvm, struct kvm_lapic *src,
			if (r < 0)
			if (r < 0)
				r = 0;
				r = 0;
			r += kvm_apic_set_irq(vcpu, irq);
			r += kvm_apic_set_irq(vcpu, irq);
		} else {
		} else if (kvm_lapic_enabled(vcpu)) {
			if (!lowest)
			if (!lowest)
				lowest = vcpu;
				lowest = vcpu;
			else if (kvm_apic_compare_prio(vcpu, lowest) < 0)
			else if (kvm_apic_compare_prio(vcpu, lowest) < 0)