Re: [PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-23 Thread Marcelo Tosatti
On Wed, Mar 18, 2015 at 07:38:22PM +0100, Radim Krčmář wrote: > kvm_ioapic_update_eoi() wasn't called if directed EOI was enabled. > We need to do that for irq notifiers. (Like with edge interrupts.) > > Fix it by skipping EOI broadcast only. > > Bug: https://bugzilla.kernel.org/show_bug.cgi?id=

Re: [PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-20 Thread Radim Krčmář
2015-03-19 18:44-0300, Marcelo Tosatti: > On Wed, Mar 18, 2015 at 07:38:22PM +0100, Radim Krčmář wrote: > > kvm_ioapic_update_eoi() wasn't called if directed EOI was enabled. > > We need to do that for irq notifiers. (Like with edge interrupts.) > > > > Fix it by skipping EOI broadcast only. > >

Re: [PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-19 Thread Marcelo Tosatti
On Wed, Mar 18, 2015 at 07:38:22PM +0100, Radim Krčmář wrote: > kvm_ioapic_update_eoi() wasn't called if directed EOI was enabled. > We need to do that for irq notifiers. (Like with edge interrupts.) > > Fix it by skipping EOI broadcast only. > > Bug: https://bugzilla.kernel.org/show_bug.cgi?id=

Re: [PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-19 Thread Radim Krčmář
2015-03-19 18:24+0100, Paolo Bonzini: > > diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c > > @@ -833,8 +833,7 @@ int kvm_apic_compare_prio(struct kvm_vcpu *vcpu1, > > struct kvm_vcpu *vcpu2) > > - if (!(kvm_apic_get_reg(apic, APIC_SPIV) & APIC_SPIV_DIRECTED_EOI) && > > - kvm_ioap

Re: [PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-19 Thread Paolo Bonzini
On 18/03/2015 19:38, Radim Krčmář wrote: > kvm_ioapic_update_eoi() wasn't called if directed EOI was enabled. > We need to do that for irq notifiers. (Like with edge interrupts.) > > Fix it by skipping EOI broadcast only. > > Bug: https://bugzilla.kernel.org/show_bug.cgi?id=82211 > Signed-off-

Re: [PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-18 Thread Bandan Das
Radim Krčmář writes: > kvm_ioapic_update_eoi() wasn't called if directed EOI was enabled. > We need to do that for irq notifiers. (Like with edge interrupts.) > > Fix it by skipping EOI broadcast only. > > Bug: https://bugzilla.kernel.org/show_bug.cgi?id=82211 > Signed-off-by: Radim Krčmář > --

Re: [PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-18 Thread Radim Krčmář
2015-03-18 15:37-0400, Bandan Das: > Radim Krčmář writes: > > kvm_ioapic_update_eoi() wasn't called if directed EOI was enabled. > > We need to do that for irq notifiers. (Like with edge interrupts.) > > Wow! It's interesting that this path is only hit with Xen as guest. Linux doesn't use direc

Re: [PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-18 Thread Bandan Das
Radim Krčmář writes: > kvm_ioapic_update_eoi() wasn't called if directed EOI was enabled. > We need to do that for irq notifiers. (Like with edge interrupts.) Wow! It's interesting that this path is only hit with Xen as guest. I always thought of directed EOI as a "security feature" since broad

[PATCH] KVM: x86: call irq notifiers with directed EOI

2015-03-18 Thread Radim Krčmář
kvm_ioapic_update_eoi() wasn't called if directed EOI was enabled. We need to do that for irq notifiers. (Like with edge interrupts.) Fix it by skipping EOI broadcast only. Bug: https://bugzilla.kernel.org/show_bug.cgi?id=82211 Signed-off-by: Radim Krčmář --- arch/x86/kvm/ioapic.c | 4 +++- ar