selftests/bpf: Fix perf_buffer test on systems w/ offline CPUs
authorAndrii Nakryiko <andriin@fb.com>
Thu, 12 Dec 2019 01:36:20 +0000 (17:36 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 11 Feb 2020 12:35:29 +0000 (04:35 -0800)
commit77bb53cb094828a31cd3c5b402899810f63073c1
treee8cba532e1d19662c9680b5c7ec9f9433bb8627f
parent5b0e9b563c01f0f3bb1a00712bc99225fbb44d07
selftests/bpf: Fix perf_buffer test on systems w/ offline CPUs

commit 91cbdf740a476cf2c744169bf407de2e3ac1f3cf upstream.

Fix up perf_buffer.c selftest to take into account offline/missing CPUs.

Fixes: ee5cf82ce04a ("selftests/bpf: test perf buffer API")
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20191212013621.1691858-1-andriin@fb.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
tools/testing/selftests/bpf/prog_tests/perf_buffer.c