OSDN Git Service

KVM: lapic: stop advertising DIRECTED_EOI when in-kernel IOAPIC is in use
authorVitaly Kuznetsov <vkuznets@redhat.com>
Fri, 9 Feb 2018 13:01:33 +0000 (14:01 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 30 May 2018 05:50:45 +0000 (07:50 +0200)
commite1d32f93981e74332f8e0efae5cba2832f098919
tree8760c81a5082f297e3760a114452cbbeee101d29
parentf59418121e7af1df60d045f2e78ead6e0b5b009d
KVM: lapic: stop advertising DIRECTED_EOI when in-kernel IOAPIC is in use

[ Upstream commit 0bcc3fb95b97ac2ca223a5a870287b37f56265ac ]

Devices which use level-triggered interrupts under Windows 2016 with
Hyper-V role enabled don't work: Windows disables EOI broadcast in SPIV
unconditionally. Our in-kernel IOAPIC implementation emulates an old IOAPIC
version which has no EOI register so EOI never happens.

The issue was discovered and discussed a while ago:
https://www.spinics.net/lists/kvm/msg148098.html

While this is a guest OS bug (it should check that IOAPIC has the required
capabilities before disabling EOI broadcast) we can workaround it in KVM:
advertising DIRECTED_EOI with in-kernel IOAPIC makes little sense anyway.

Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/x86/kvm/lapic.c