On Tue, Dec 01, 2009 at 03:36:36PM +0100, Chris Lalancette wrote: > Call it kvm_apic_in_virtual_wire_mode, which is more > correct. Also change it to not only operate properly > on the boot CPU, but on any CPU. > Currently it is assumed that if kvm_cpu_has_interrupt() returns true kvm_cpu_get_interrupt() will return valid interrupt. After this change it may not be the case any more. Suppose there are more then one vcpus in a virtual wire mode. Pic receives interrupt and multiple cpus try to inject it simultaneously. They all check that interrupt is pending by calling kvm_cpu_has_interrupt() and then try to get the vector by calling kvm_cpu_get_interrupt(). Only one vcpu will get correct value, others will get spurious interrupt. -- Gleb. -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html