selftests/powerpc/pmu: Add selftest for checking valid and invalid bhrb filter maps
authorAthira Rajeev <atrajeev@linux.vnet.ibm.com>
Fri, 10 Jun 2022 13:40:50 +0000 (19:10 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 28 Jun 2022 22:57:42 +0000 (08:57 +1000)
commitf6380e05aa92b005ac6f38be92afbdd2a0706cff
tree0b25042c781fe8fed475a7c319a560fdee0b09aa
parent11bbc524390572dfe1bd0375c7e7ab8f9ddf4b34
selftests/powerpc/pmu: Add selftest for checking valid and invalid bhrb filter maps

For PERF_SAMPLE_BRANCH_STACK sample type, different branch_sample_type,
ie branch filters are supported. All the branch filters are not
supported in powerpc. Example, power10 platform supports any, ind_call
and cond branch filters. Whereas, it is different in power9. Testcase
checks event open for invalid and valid branch sample types. The branch
types for testcase are picked from "perf_branch_sample_type" in
perf_event.h

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/20220610134113.62991-13-atrajeev@linux.vnet.ibm.com
tools/testing/selftests/powerpc/pmu/sampling_tests/Makefile
tools/testing/selftests/powerpc/pmu/sampling_tests/bhrb_filter_map_test.c [new file with mode: 0644]