From 7a0c70482580234868fcc53b8d72e31966dc7c52 Mon Sep 17 00:00:00 2001 From: Luwei Kang Date: Tue, 13 Dec 2016 14:21:26 +0100 Subject: [PATCH] x86/VPMU: clear the overflow status of which counter happened to overflow Just set the corresponding bits of counters which happened to overflow, rather than setting all the available bits of IA32_PERF_GLOBAL_OVF_CTRL when pmu interrupt happened. Signed-off-by: Luwei Kang Acked-by: Kevin Tian Reviewed-by: Jan Beulich --- xen/arch/x86/cpu/vpmu_intel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xen/arch/x86/cpu/vpmu_intel.c b/xen/arch/x86/cpu/vpmu_intel.c index e51bc4e61f..16e5afb3a7 100644 --- a/xen/arch/x86/cpu/vpmu_intel.c +++ b/xen/arch/x86/cpu/vpmu_intel.c @@ -837,7 +837,7 @@ static int core2_vpmu_do_interrupt(struct cpu_user_regs *regs) if ( is_pmc_quirk ) handle_pmc_quirk(msr_content); core2_vpmu_cxt->global_status |= msr_content; - msr_content = ~global_ovf_ctrl_mask; + msr_content &= ~global_ovf_ctrl_mask; wrmsrl(MSR_CORE_PERF_GLOBAL_OVF_CTRL, msr_content); } else -- 2.30.2