]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86/xen: handle PV spinlocks slowpath
authorBoris Ostrovsky <boris.ostrovsky@oracle.com>
Thu, 3 Mar 2022 15:41:26 +0000 (15:41 +0000)
committerPaolo Bonzini <pbonzini@redhat.com>
Sat, 2 Apr 2022 09:41:17 +0000 (05:41 -0400)
commit87cd5a9828f4cea66591190da5557d3bd6ad2762
tree1567c60b602208d83bd54d4c8899fe83590615f7
parentafa9e7746b269a07e5bcb1717f7518b85236a5f9
KVM: x86/xen: handle PV spinlocks slowpath

Add support for SCHEDOP_poll hypercall.

This implementation is optimized for polling for a single channel, which
is what Linux does. Polling for multiple channels is not especially
efficient (and has not been tested).

PV spinlocks slow path uses this hypercall, and explicitly crash if it's
not supported.

[ dwmw2: Rework to use kvm_vcpu_halt(), not supported for 32-bit guests ]

Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Message-Id: <20220303154127.202856-17-dwmw2@infradead.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/xen.c
tools/testing/selftests/kvm/x86_64/xen_shinfo_test.c