aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/include
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2013-09-05 23:11:18 -0400
committerAlexander Graf <agraf@suse.de>2013-10-17 08:44:59 -0400
commit14941789f2a13cd89e2dd567c4f708e571ab714e (patch)
tree71149df5b0ab4e2790c368d7addf90fb920b0caa /arch/powerpc/include
parent3b7834743f9492e3509930feb4ca47135905e640 (diff)
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>
Diffstat (limited to 'arch/powerpc/include')
-rw-r--r--arch/powerpc/include/asm/kvm_host.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/powerpc/include/asm/kvm_host.h b/arch/powerpc/include/asm/kvm_host.h
index 0866230b7c2d..d9b21af62610 100644
--- a/arch/powerpc/include/asm/kvm_host.h
+++ b/arch/powerpc/include/asm/kvm_host.h
@@ -493,6 +493,8 @@ struct kvm_vcpu_arch {
493 493
494 u64 mmcr[3]; 494 u64 mmcr[3];
495 u32 pmc[8]; 495 u32 pmc[8];
496 u64 siar;
497 u64 sdar;
496 498
497#ifdef CONFIG_KVM_EXIT_TIMING 499#ifdef CONFIG_KVM_EXIT_TIMING
498 struct mutex exit_timing_lock; 500 struct mutex exit_timing_lock;