diff options
author | Athira Rajeev <atrajeev@linux.vnet.ibm.com> | 2021-02-03 07:55:35 +0100 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2021-02-08 15:09:44 +0100 |
commit | 91f3469a43fd1fb831649c2a2e684bf5ad4818b2 (patch) | |
tree | 16019c3546dba5978321de157634d6be34a81530 /arch/powerpc/perf/perf_regs.c | |
parent | powerpc/pkeys: Remove unused code (diff) | |
download | linux-91f3469a43fd1fb831649c2a2e684bf5ad4818b2.tar.xz linux-91f3469a43fd1fb831649c2a2e684bf5ad4818b2.zip |
powerpc/perf: Include PMCs as part of per-cpu cpuhw_events struct
To support capturing of PMC's as part of extended registers, the
value of SPR's PMC1 to PMC6 has to be saved in the starting of PMI
interrupt handler. This is needed since we are resetting the
overflown PMC before creating sample and hence directly reading
SPRN_PMCx in 'perf_reg_value' will be capturing the modified value.
To solve this, add a per-cpu array as part of structure cpu_hw_events
and use this array to capture PMC values in the perf interrupt handler.
Patch also re-factor's the interrupt handler code to use this per-cpu
array instead of current local array.
Signed-off-by: Athira Rajeev <atrajeev@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/1612335337-1888-2-git-send-email-atrajeev@linux.vnet.ibm.com
Diffstat (limited to 'arch/powerpc/perf/perf_regs.c')
0 files changed, 0 insertions, 0 deletions