[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YmfLU/VMQI0g0Ck0@rric.localdomain>
Date: Tue, 26 Apr 2022 12:37:07 +0200
From: Robert Richter <rrichter@....com>
To: Ravi Bangoria <ravi.bangoria@....com>
CC: <peterz@...radead.org>, <acme@...nel.org>, <mingo@...hat.com>,
<mark.rutland@....com>, <jolsa@...nel.org>, <namhyung@...nel.org>,
<tglx@...utronix.de>, <bp@...en8.de>, <irogers@...gle.com>,
<yao.jin@...ux.intel.com>, <james.clark@....com>,
<leo.yan@...aro.org>, <kan.liang@...ux.intel.com>,
<ak@...ux.intel.com>, <eranian@...gle.com>,
<like.xu.linux@...il.com>, <x86@...nel.org>,
<linux-perf-users@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
<sandipan.das@....com>, <ananth.narayan@....com>,
<kim.phillips@....com>, <santosh.shukla@....com>
Subject: Re: [PATCH 4/6] perf/tool: Parse non-cpu pmu capabilities
On 25.04.22 10:13:21, Ravi Bangoria wrote:
> diff --git a/tools/perf/Documentation/perf.data-file-format.txt b/tools/perf/Documentation/perf.data-file-format.txt
> index f56d0e0fbff6..dea3acb36558 100644
> --- a/tools/perf/Documentation/perf.data-file-format.txt
> +++ b/tools/perf/Documentation/perf.data-file-format.txt
> @@ -435,6 +435,24 @@ struct {
> } [nr_pmu];
> };
>
> + HEADER_PMU_CAPS = 32,
> +
> + List of pmu capabilities (except cpu pmu which is already
> + covered by HEADER_CPU_PMU_CAPS)
> +
> +struct {
> + u32 nr_pmus;
> + struct {
> + u8 core_type; /* For hybrid topology */
> + char pmu_name[];
> + u16 nr_caps;
> + struct {
> + char name[];
> + char value[];
> + } [nr_caps];
> + } [nr_pmus];
> +};
> +
This looks quite a bit complex and special.
Why not just reusing struct nr_cpu_pmu_caps (id 28)? Rename it and
introduce macros for backwards compatability if needed.
pmu_name is already encoded in sysfs and core_type could be a caps
value?
-Robert
Powered by blists - more mailing lists