]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drivers/perf: hisi: Refactor the event configuration of L3C PMU
authorYicong Yang <yangyicong@hisilicon.com>
Fri, 29 Aug 2025 10:14:24 +0000 (18:14 +0800)
committerWill Deacon <will@kernel.org>
Mon, 22 Sep 2025 12:14:38 +0000 (13:14 +0100)
commitb3abb08d6f628a76c36bf7da9508e1a67bf186a0
treed96bc24cbe0a8c59e033c04cece7eb0405dfb622
parentede339ff61c61a1ac3bedd01528e4d701d4aea22
drivers/perf: hisi: Refactor the event configuration of L3C PMU

The event register is configured using hisi_pmu::base directly since
only one address space is supported for L3C PMU. We need to extend if
events configuration locates in different address space. In order to
make preparation for such hardware, extract the event register
configuration to separate function using hw_perf_event::event_base as
each event's base address.  Implement a private
hisi_uncore_ops::get_event_idx() callback for initialize the event_base
besides get the hardware index.

No functional changes intended.

Acked-by: Jonathan Cameron <jonathan.cameron@huawei.com>
Signed-off-by: Yicong Yang <yangyicong@hisilicon.com>
Signed-off-by: Yushan Wang <wangyushan12@huawei.com>
Signed-off-by: Will Deacon <will@kernel.org>
drivers/perf/hisilicon/hisi_uncore_l3c_pmu.c