summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorYonghong Song <yhs@fb.com>2020-07-20 18:34:01 +0200
committerAlexei Starovoitov <ast@kernel.org>2020-07-21 22:26:26 +0200
commit0f12e584b241285cf60a6227f3771fa444cfcf76 (patch)
tree2168b0dbe894b1966d86451de379cffcad31f37a /scripts
parenttools/bpf: Sync btf_ids.h to tools (diff)
downloadlinux-0f12e584b241285cf60a6227f3771fa444cfcf76.tar.xz
linux-0f12e584b241285cf60a6227f3771fa444cfcf76.zip
bpf: Add BTF_ID_LIST_GLOBAL in btf_ids.h
Existing BTF_ID_LIST used a local static variable to store btf_ids. This patch provided a new macro BTF_ID_LIST_GLOBAL to store btf_ids in a global variable which can be shared among multiple files. The existing BTF_ID_LIST is still retained. Two reasons. First, BTF_ID_LIST is also used to build btf_ids for helper arguments which typically is an array of 5. Since typically different helpers have different signature, it makes little sense to share them. Second, some current computed btf_ids are indeed local. If later those btf_ids are shared between different files, they can use BTF_ID_LIST_GLOBAL then. Signed-off-by: Yonghong Song <yhs@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Jiri Olsa <jolsa@redhat.com> Link: https://lore.kernel.org/bpf/20200720163401.1393159-1-yhs@fb.com
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions