+11
−4
+2
−0
Loading
mainline inclusion from mainline-v6.0-rc1 commit 3339ec44 category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/IAU6ZD Reference: https://github.com/torvalds/linux/commit/3339ec44be7f9963c82d5d21e163f16f96e5ca58 -------------------------------- commit 3339ec44 upstream In addition to returning nr_caps, cache it locally in struct perf_pmu. Similarly, cache status of whether caps sysfs has already been parsed or not. These will help to avoid parsing sysfs every time the function gets called. Reviewed-by:Kan Liang <kan.liang@linux.intel.com> Signed-off-by:
Ravi Bangoria <ravi.bangoria@amd.com> Acked-by:
Namhyung Kim <namhyung@kernel.org> Cc: Ananth Narayan <ananth.narayan@amd.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Ian Rogers <irogers@google.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: James Clark <james.clark@arm.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Kim Phillips <kim.phillips@amd.com> Cc: Leo Yan <leo.yan@linaro.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Robert Richter <rrichter@amd.com> Cc: Sandipan Das <sandipan.das@amd.com> Cc: Santosh Shukla <santosh.shukla@amd.com> Cc: Stephane Eranian <eranian@google.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: like.xu.linux@gmail.com Cc: x86@kernel.org Link: https://lore.kernel.org/r/20220604044519.594-3-ravi.bangoria@amd.com Signed-off-by:
Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by:
chaithanyaLagisetty <lagisettyvenkata.nagachaitanya@amd.com> Signed-off-by:
PvsNarasimha <PVS.NarasimhaRao@amd.com>