OSDN Git Service

perf/x86/intel/uncore: Enable IIO stacks to PMON mapping for multi-segment SKX
authorAlexander Antonov <alexander.antonov@linux.intel.com>
Tue, 23 Mar 2021 15:05:07 +0000 (18:05 +0300)
committerPeter Zijlstra <peterz@infradead.org>
Fri, 2 Apr 2021 08:04:55 +0000 (10:04 +0200)
commitcface0326a6c2ae5c8f47bd466f07624b3e348a7
tree8628e77be174c18333e9af928bfdcbe3745cf093
parentc4c55e362a521d763356b9e02bc9a4348c71a471
perf/x86/intel/uncore: Enable IIO stacks to PMON mapping for multi-segment SKX

IIO stacks to PMON mapping on Skylake servers is exposed through introduced
early attributes /sys/devices/uncore_iio_<pmu_idx>/dieX, where dieX is a
file which holds "Segment:Root Bus" for PCIe root port which can
be monitored by that IIO PMON block. These sysfs attributes are disabled
for multiple segment topologies except VMD domains which start at 0x10000.
This patch removes the limitation and enables IIO stacks to PMON mapping
for multi-segment Skylake servers by introducing segment-aware
intel_uncore_topology structure and attributing the topology configuration
to the segment in skx_iio_get_topology() function.

Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Alexander Antonov <alexander.antonov@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Kan Liang <kan.liang@linux.intel.com>
Reviewed-by: Andi Kleen <ak@linux.intel.com>
Tested-by: Kyle Meyer <kyle.meyer@hpe.com>
Link: https://lkml.kernel.org/r/20210323150507.2013-1-alexander.antonov@linux.intel.com
arch/x86/events/intel/uncore.c
arch/x86/events/intel/uncore.h
arch/x86/events/intel/uncore_snbep.c