libbpf: Update BTF reloc support to latest Clang format
authorAndrii Nakryiko <andriin@fb.com>
Tue, 15 Oct 2019 18:28:45 +0000 (11:28 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Tue, 15 Oct 2019 23:06:05 +0000 (16:06 -0700)
commit511bb0085c6fe48353c35cd3d25f4f8720579a6d
tree241b6942492dc14948b62cffd68856743323fd6d
parent14f2cf607ccd1fa05e767f0191fd5d07b35534c2
libbpf: Update BTF reloc support to latest Clang format

BTF offset reloc was generalized in recent Clang into field relocation,
capturing extra u32 field, specifying what aspect of captured field
needs to be relocated. This changes .BTF.ext's record size for this
relocation from 12 bytes to 16 bytes. Given these format changes
happened in Clang before official released version, it's ok to not
support outdated 12-byte record size w/o breaking ABI.

Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20191015182849.3922287-2-andriin@fb.com
tools/lib/bpf/btf.c
tools/lib/bpf/btf.h
tools/lib/bpf/libbpf.c
tools/lib/bpf/libbpf_internal.h