diff options
| author | Alexei Starovoitov <ast@kernel.org> | 2020-07-13 10:42:03 -0700 |
|---|---|---|
| committer | Alexei Starovoitov <ast@kernel.org> | 2020-07-13 14:30:57 -0700 |
| commit | 24a38b7c0c2c17f7b86c29f82beb7f2779704ca3 (patch) | |
| tree | 72725e347309aa4c0ad196b34978f359c54d2ab6 /scripts | |
| parent | eef8a42d6ce087d1c81c960ae0d14f955b742feb (diff) | |
| parent | cc15a20d5f3abc3cbd7911b70156b7b9e2bc7d41 (diff) | |
| download | linux-24a38b7c0c2c17f7b86c29f82beb7f2779704ca3.tar.gz linux-24a38b7c0c2c17f7b86c29f82beb7f2779704ca3.tar.bz2 linux-24a38b7c0c2c17f7b86c29f82beb7f2779704ca3.zip | |
Merge branch 'resolve_btfids'
Jiri Olsa says:
====================
This patchset adds:
- support to generate BTF ID lists that are resolved during
kernel linking and usable within kernel code with following
macros:
BTF_ID_LIST(bpf_skb_output_btf_ids)
BTF_ID(struct, sk_buff)
and access it in kernel code via:
extern u32 bpf_skb_output_btf_ids[];
- resolve_btfids tool that scans elf object for .BTF_ids
section and resolves its symbols with BTF ID values
- resolving of bpf_ctx_convert struct and several other
objects with BTF_ID_LIST
v7 changes:
- added more acks [Andrii]
- added some name-conflicting entries and fixed resolve_btfids
to process them properly [Andrii]
- changed bpf_get_task_stack_proto to use BTF_IDS_LIST/BTF_ID
macros [Andrii]
- fixed selftest build for resolve_btfids test
====================
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/link-vmlinux.sh | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/link-vmlinux.sh b/scripts/link-vmlinux.sh index 92dd745906f4..e26f02dbedee 100755 --- a/scripts/link-vmlinux.sh +++ b/scripts/link-vmlinux.sh @@ -336,6 +336,12 @@ fi vmlinux_link vmlinux "${kallsymso}" ${btf_vmlinux_bin_o} +# fill in BTF IDs +if [ -n "${CONFIG_DEBUG_INFO_BTF}" ]; then +info BTFIDS vmlinux +${RESOLVE_BTFIDS} vmlinux +fi + if [ -n "${CONFIG_BUILDTIME_TABLE_SORT}" ]; then info SORTTAB vmlinux if ! sorttable vmlinux; then |
