[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <95bf3dca-c6d1-02c8-40b6-8bb29a3a7a36@redhat.com>
Date:   Fri, 10 Dec 2021 10:03:19 +0100
From:   Paolo Bonzini <pbonzini@...hat.com>
To:     Like Xu <like.xu.linux@...il.com>
Cc:     jmattson@...gle.com, wanpengli@...cent.com,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        kvm@...r.kernel.org
Subject: Re: [PATCH] KVM: x86: avoid out of bounds indices for fixed
 performance counters
On 12/10/21 09:59, Like Xu wrote:
> 
> How about introducing a static "struct x86_pmu_capability" variable [1] 
> so that we can
> 
> (1) setup num_counters_fixed just once in the kvm_init_pmu_capability(), 
> and
> (2) avoid repeated calls to perf_get_x86_pmu_capability() ;
Yes, that works.
> [1] 
> https://lore.kernel.org/kvm/20210806133802.3528-17-lingshan.zhu@intel.com/
> By the way, do you need a re-based version of the guest PBES feature ?
Sure, please send one.
Paolo
Powered by blists - more mailing lists