summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/bpf/verifier/map_ptr.c
diff options
context:
space:
mode:
authorBjörn Töpel <bjorn.topel@gmail.com>2020-11-18 08:16:40 +0100
committerAndrii Nakryiko <andrii@kernel.org>2020-11-18 17:45:35 -0800
commit6007b23cc7555df882be870433dc589841d4eb06 (patch)
tree98b969cfd7612f38e05c6cda6d5382ac0a8b36c6 /tools/testing/selftests/bpf/verifier/map_ptr.c
parentc77b0589ca29ad1859fe7d7c1ecd63c0632379fa (diff)
selftests/bpf: Mark tests that require unaligned memory access
A lot of tests require unaligned memory access to work. Mark the tests as such, so that they can be avoided on unsupported architectures such as RISC-V. Signed-off-by: Björn Töpel <bjorn.topel@gmail.com> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Acked-by: Luke Nelson <luke.r.nels@gmail.com> Link: https://lore.kernel.org/bpf/20201118071640.83773-4-bjorn.topel@gmail.com
Diffstat (limited to 'tools/testing/selftests/bpf/verifier/map_ptr.c')
-rw-r--r--tools/testing/selftests/bpf/verifier/map_ptr.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/bpf/verifier/map_ptr.c b/tools/testing/selftests/bpf/verifier/map_ptr.c
index 637f9293bda8..b117bdd3806d 100644
--- a/tools/testing/selftests/bpf/verifier/map_ptr.c
+++ b/tools/testing/selftests/bpf/verifier/map_ptr.c
@@ -44,6 +44,7 @@
.errstr_unpriv = "bpf_array access is allowed only to CAP_PERFMON and CAP_SYS_ADMIN",
.result = REJECT,
.errstr = "cannot access ptr member ops with moff 0 in struct bpf_map with off 1 size 4",
+ .flags = F_NEEDS_EFFICIENT_UNALIGNED_ACCESS,
},
{
"bpf_map_ptr: read ops field accepted",