]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: PPC: Book3S HV: Save/restore SIAR and SDAR along with other PMU registers
authorPaul Mackerras <paulus@samba.org>
Fri, 6 Sep 2013 03:11:18 +0000 (13:11 +1000)
committerAlexander Graf <agraf@suse.de>
Thu, 17 Oct 2013 12:44:59 +0000 (14:44 +0200)
commitcbed5deacc3552bffc0121524f0b36ab5364c67b
tree71149df5b0ab4e2790c368d7addf90fb920b0caa
parentb57a6d93901a4cf76cc0b8b133d1077422774505
KVM: PPC: Book3S HV: Save/restore SIAR and SDAR along with other PMU registers

Currently we are not saving and restoring the SIAR and SDAR registers in
the PMU (performance monitor unit) on guest entry and exit.  The result
is that performance monitoring tools in the guest could get false
information about where a program was executing and what data it was
accessing at the time of a performance monitor interrupt.  This fixes
it by saving and restoring these registers along with the other PMU
registers on guest entry/exit.

This also provides a way for userspace to access these values for a
vcpu via the one_reg interface.

Signed-off-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Alexander Graf <agraf@suse.de>
arch/powerpc/include/asm/kvm_host.h
arch/powerpc/kernel/asm-offsets.c
arch/powerpc/kvm/book3s_hv.c
arch/powerpc/kvm/book3s_hv_rmhandlers.S