]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: PPC: Book3S HV: Speed up wakeups of CPUs on HV KVM
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Wed, 17 Apr 2013 20:30:50 +0000 (20:30 +0000)
committerAlexander Graf <agraf@suse.de>
Fri, 26 Apr 2013 18:27:31 +0000 (20:27 +0200)
commit6ccfd8fbc643a9adac1a7fa501a1acf5e34a2c1b
tree4ecaa9c41857cf4b380f54017830e2aeb8dc56fe
parent927f5239e8b5902d64f7859c4c49c3c8baa2c846
KVM: PPC: Book3S HV: Speed up wakeups of CPUs on HV KVM

Currently, we wake up a CPU by sending a host IPI with
smp_send_reschedule() to thread 0 of that core, which will take all
threads out of the guest, and cause them to re-evaluate their
interrupt status on the way back in.

This adds a mechanism to differentiate real host IPIs from IPIs sent
by KVM for guest threads to poke each other, in order to target the
guest threads precisely when possible and avoid that global switch of
the core to host state.

We then use this new facility in the in-kernel XICS code.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Alexander Graf <agraf@suse.de>
arch/powerpc/include/asm/kvm_book3s_asm.h
arch/powerpc/include/asm/kvm_ppc.h
arch/powerpc/kernel/asm-offsets.c
arch/powerpc/kvm/book3s_hv.c
arch/powerpc/kvm/book3s_hv_rmhandlers.S
arch/powerpc/kvm/book3s_xics.c
arch/powerpc/sysdev/xics/icp-native.c