Re: [PATCH v3 1/1] KVM: ARM64: Fix the issues when guest PMCCFILTR is configured

2016-11-17 Thread Marc Zyngier
On 17/11/16 13:30, Will Deacon wrote: > On Wed, Nov 16, 2016 at 11:09:20AM -0600, Wei Huang wrote: >> KVM calls kvm_pmu_set_counter_event_type() when PMCCFILTR is configured. >> But this function can't deals with PMCCFILTR correctly because the evtCount >> bits of PMCCFILTR, which is reserved 0,

Re: [PATCH v3 1/1] KVM: ARM64: Fix the issues when guest PMCCFILTR is configured

2016-11-17 Thread Will Deacon
On Wed, Nov 16, 2016 at 11:09:20AM -0600, Wei Huang wrote: > KVM calls kvm_pmu_set_counter_event_type() when PMCCFILTR is configured. > But this function can't deals with PMCCFILTR correctly because the evtCount > bits of PMCCFILTR, which is reserved 0, conflits with the SW_INCR event > type of

[PATCH v3 1/1] KVM: ARM64: Fix the issues when guest PMCCFILTR is configured

2016-11-16 Thread Wei Huang
KVM calls kvm_pmu_set_counter_event_type() when PMCCFILTR is configured. But this function can't deals with PMCCFILTR correctly because the evtCount bits of PMCCFILTR, which is reserved 0, conflits with the SW_INCR event type of other PMXEVTYPER registers. To fix it, when eventsel == 0, this