selftests/bpf: add CO-RE relocs nesting tests
authorAndrii Nakryiko <andriin@fb.com>
Wed, 7 Aug 2019 21:39:55 +0000 (14:39 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Wed, 7 Aug 2019 21:43:49 +0000 (14:43 -0700)
commitec6438a988a43dcb03f0a04f3f51a48aba54764a
tree376e2801ac2e543aabf2fecc6ff6f0995e647324
parent002d3afce65518dc5dfc398a37c2be2a6bf559c4
selftests/bpf: add CO-RE relocs nesting tests

Add a bunch of test validating correct handling of nested
structs/unions.

Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Acked-by: Song Liu <songliubraving@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
16 files changed:
tools/testing/selftests/bpf/prog_tests/core_reloc.c
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___anon_embed.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___dup_compat_types.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___err_array_container.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___err_array_field.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___err_dup_incompat_types.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___err_missing_container.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___err_missing_field.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___err_nonstruct_container.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___err_partial_match_dups.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___err_too_deep.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___extra_nesting.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/btf__core_reloc_nesting___struct_union_mixup.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/core_reloc_types.h
tools/testing/selftests/bpf/progs/test_core_reloc_nesting.c [new file with mode: 0644]