aboutsummaryrefslogtreecommitdiffstats
path: root/arch/s390/kernel/perf_pai_crypto.c
diff options
context:
space:
mode:
authorThomas Richter <tmricht@linux.ibm.com>2022-06-10 15:19:00 +0200
committerAlexander Gordeev <agordeev@linux.ibm.com>2022-06-23 17:23:59 +0200
commitbe857b7f77d130dbbd47c91fc35198b040f35865 (patch)
treee0b5f4657a7dfef72c6362a6f9c5dfd90528ad47 /arch/s390/kernel/perf_pai_crypto.c
parents390/crash: make copy_oldmem_page() return number of bytes copied (diff)
downloadlinux-dev-be857b7f77d130dbbd47c91fc35198b040f35865.tar.xz
linux-dev-be857b7f77d130dbbd47c91fc35198b040f35865.zip
s390/cpumf: Handle events cycles and instructions identical
Events CPU_CYCLES and INSTRUCTIONS can be submitted with two different perf_event attribute::type values: - PERF_TYPE_HARDWARE: when invoked via perf tool predefined events name cycles or cpu-cycles or instructions. - pmu->type: when invoked via perf tool event name cpu_cf/CPU_CYLCES/ or cpu_cf/INSTRUCTIONS/. This invocation also selects the PMU to which the event belongs. Handle both type of invocations identical for events CPU_CYLCES and INSTRUCTIONS. They address the same hardware. The result is different when event modifier exclude_kernel is also set. Invocation with event modifier for user space event counting fails. Output before: # perf stat -e cpum_cf/cpu_cycles/u -- true Performance counter stats for 'true': <not supported> cpum_cf/cpu_cycles/u 0.000761033 seconds time elapsed 0.000076000 seconds user 0.000725000 seconds sys # Output after: # perf stat -e cpum_cf/cpu_cycles/u -- true Performance counter stats for 'true': 349,613 cpum_cf/cpu_cycles/u 0.000844143 seconds time elapsed 0.000079000 seconds user 0.000800000 seconds sys # Fixes: 6a82e23f45fe ("s390/cpumf: Adjust registration of s390 PMU device drivers") Signed-off-by: Thomas Richter <tmricht@linux.ibm.com> Acked-by: Sumanth Korikkar <sumanthk@linux.ibm.com> [agordeev@linux.ibm.com corrected commit ID of Fixes commit] Signed-off-by: Alexander Gordeev <agordeev@linux.ibm.com>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions