[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5FC3163CFD30C246ABAA99954A238FA838793F64@FRAEML521-MBX.china.huawei.com>
Date: Wed, 3 Oct 2018 08:52:35 +0000
From: Shameerali Kolothum Thodi <shameerali.kolothum.thodi@...wei.com>
To: Robin Murphy <robin.murphy@....com>,
Jean-Philippe Brucker <jean-philippe.brucker@....com>,
"lorenzo.pieralisi@....com" <lorenzo.pieralisi@....com>
CC: "mark.rutland@....com" <mark.rutland@....com>,
"vkilari@...eaurora.org" <vkilari@...eaurora.org>,
"neil.m.leeder@...il.com" <neil.m.leeder@...il.com>,
"pabba@...eaurora.org" <pabba@...eaurora.org>,
John Garry <john.garry@...wei.com>,
"will.deacon@....com" <will.deacon@....com>,
"rruigrok@...eaurora.org" <rruigrok@...eaurora.org>,
Linuxarm <linuxarm@...wei.com>,
"linux-acpi@...r.kernel.org" <linux-acpi@...r.kernel.org>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"Guohanjun (Hanjun Guo)" <guohanjun@...wei.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH v3 2/3] perf: add arm64 smmuv3 pmu driver
> -----Original Message-----
> From: Robin Murphy [mailto:robin.murphy@....com]
> Sent: 02 October 2018 17:35
> To: Jean-Philippe Brucker <jean-philippe.brucker@....com>; Shameerali
> Kolothum Thodi <shameerali.kolothum.thodi@...wei.com>;
> lorenzo.pieralisi@....com
> Cc: mark.rutland@....com; vkilari@...eaurora.org;
> neil.m.leeder@...il.com; pabba@...eaurora.org; John Garry
> <john.garry@...wei.com>; will.deacon@....com; rruigrok@...eaurora.org;
> Linuxarm <linuxarm@...wei.com>; linux-acpi@...r.kernel.org; linux-arm-
> kernel@...ts.infradead.org; Guohanjun (Hanjun Guo)
> <guohanjun@...wei.com>; linux-kernel@...r.kernel.org
> Subject: Re: [PATCH v3 2/3] perf: add arm64 smmuv3 pmu driver
>
> On 02/10/18 17:19, Jean-Philippe Brucker wrote:
> > On 02/10/2018 15:11, Jean-Philippe Brucker wrote:
> >>> + cfgr = readl_relaxed(smmu_pmu->reg_base + SMMU_PMCG_CFGR);
> >
> > Something I missed previously: when SMMU_PMCG_CFGR.SID_FILTER_TYPE
> is 1,
> > filtering for all counters is configured by SMMU_PMCG_SMR0 and
> > SMMU_PMCG_EVTYPER0 (instead of having one separate filter per counter).
>
> Oh, I hadn't even noticed it had that mode as well...
Thanks Jean. Missed that completely.
> > In that mode with your patch, if the user applies a filter to the first
> > event in the list passed to perf, it will be applied to all events.
> > Filter applied on any subsequent event will be ignored. Could we make
> > this more explicit? Maybe in the probe print that the PMCG is
> > global-filtering, and when attempting to apply a filter to something
> > else than EVCNTR0, return an error?
>
> FWIW filtering is always per-counter-group on the SMMUv2 PMU, and it's
> actually pretty straightforward to cope with - pmu->add() just needs to
> reject the event if one with an incompatible configuration is already
> scheduled, so perf core handles it much like having more events than
> counters, by rotating the mutually-exclusive sets.
I will take a look and address this in next version.
Thanks,
Shameer
Powered by blists - more mailing lists