selftests/bpf: Use cpu_number only on arches that have it
authorIlya Leoshkevich <iii@linux.ibm.com>
Wed, 13 Oct 2021 16:08:59 +0000 (18:08 +0200)
committerAndrii Nakryiko <andrii@kernel.org>
Wed, 20 Oct 2021 18:40:01 +0000 (11:40 -0700)
commitb16d12f3900283e00aded9131ba1e9b2880513c3
treed2554f370313521bfa3386d6b1ef713ec991c6c4
parentb599015f044df53e93ad0a2957b615bc1a26bf73
selftests/bpf: Use cpu_number only on arches that have it

cpu_number exists only on Intel and aarch64, so skip the test involing
it on other arches. An alternative would be to replace it with an
exported non-ifdefed primitive-typed percpu variable from the common
code, but there appears to be none.

Signed-off-by: Ilya Leoshkevich <iii@linux.ibm.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20211013160902.428340-2-iii@linux.ibm.com
tools/testing/selftests/bpf/prog_tests/btf_dump.c