]> git.baikalelectronics.ru Git - kernel.git/commit
selftests/bpf: Fix test_vmlinux test to use bpf_probe_read_user()
authorAndrii Nakryiko <andriin@fb.com>
Tue, 18 Aug 2020 21:33:54 +0000 (14:33 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Wed, 19 Aug 2020 00:16:15 +0000 (17:16 -0700)
commit350b7b773f79ea5be30852db0957167b9a47c2fa
tree82961c0dc05e1d217448e8e82bc899a24e71a340
parent6daa04b945175810e20f6c1c2ef40406809186e2
selftests/bpf: Fix test_vmlinux test to use bpf_probe_read_user()

The test is reading UAPI kernel structure from user-space. So it doesn't need
CO-RE relocations and has to use bpf_probe_read_user().

Fixes: c27689914203 ("selftests/bpf: Add vmlinux.h selftest exercising tracing of syscalls")
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20200818213356.2629020-6-andriin@fb.com
tools/testing/selftests/bpf/progs/test_vmlinux.c