diff options
author | Michael Petlan <mpetlan@redhat.com> | 2021-08-05 18:06:11 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-09-26 14:08:57 +0200 |
commit | ebcd3fd9207c98f0c01c317ef3aca7f2df41b72d (patch) | |
tree | e38fc0a293d3d7dfd4ed618b6d1400c0acb81811 /tools/perf | |
parent | fa64b08931ee27bec3513aed8f7936e99b8d1212 (diff) |
perf test: Fix bpf test sample mismatch reporting
commit 3e11300cdfd5f1bc13a05dfc6dccf69aca5dd1dc upstream.
When the expected sample count in the condition changed, the message
needs to be changed too, otherwise we'll get:
0x1001f2091d8: mmap mask[0]:
BPF filter result incorrect, expected 56, got 56 samples
Fixes: 4b04e0decd2518e5 ("perf test: Fix basic bpf filtering test")
Signed-off-by: Michael Petlan <mpetlan@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Sumanth Korikkar <sumanthk@linux.ibm.com>
Link: https //lore.kernel.org/r/20210805160611.5542-1-mpetlan@redhat.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf')
-rw-r--r-- | tools/perf/tests/bpf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/tests/bpf.c b/tools/perf/tests/bpf.c index 8345ff4acedf..e5832b74a845 100644 --- a/tools/perf/tests/bpf.c +++ b/tools/perf/tests/bpf.c @@ -199,7 +199,7 @@ static int do_test(struct bpf_object *obj, int (*func)(void), } if (count != expect * evlist->core.nr_entries) { - pr_debug("BPF filter result incorrect, expected %d, got %d samples\n", expect, count); + pr_debug("BPF filter result incorrect, expected %d, got %d samples\n", expect * evlist->core.nr_entries, count); goto out_delete_evlist; } |