]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drivers/perf: hisi: Export associated CPUs of each PMU through sysfs
authorYicong Yang <yangyicong@hisilicon.com>
Tue, 10 Dec 2024 14:15:23 +0000 (22:15 +0800)
committerWill Deacon <will@kernel.org>
Tue, 10 Dec 2024 15:57:24 +0000 (15:57 +0000)
commit3b051bb7cb4344d12b9b9b4974c77706462d4246
tree8c943f9729a13325f012c827a9d645c31d01932b
parent8688c01e313d542124fae82e82c8d6d5c073899f
drivers/perf: hisi: Export associated CPUs of each PMU through sysfs

Although the event of the uncore PMU can only be opened on a single
CPU, some PMU does have the affinity on a range of CPUs. For example
the L3C PMU is associated to the CPUs sharing the L3T it monitors.
Users may infer this affinity by the PMU name which may have SCCL ID
and CCL ID encoded (for L3C etc), but it's not that straightforward.
So export this information by adding an "associated_cpus" sysfs
attribute then user can get this directly.

Reviewed-by: Jonathan Cameron <Joanthan.Cameron@huawei.com>
Signed-off-by: Yicong Yang <yangyicong@hisilicon.com>
Link: https://lore.kernel.org/r/20241210141525.37788-9-yangyicong@huawei.com
Signed-off-by: Will Deacon <will@kernel.org>
Documentation/admin-guide/perf/hisi-pmu.rst
drivers/perf/hisilicon/hisi_uncore_pmu.c