[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200720195840.GO760733@krava>
Date: Mon, 20 Jul 2020 21:58:40 +0200
From: Jiri Olsa <jolsa@...hat.com>
To: Yonghong Song <yhs@...com>
Cc: bpf@...r.kernel.org, netdev@...r.kernel.org,
Alexei Starovoitov <ast@...nel.org>,
Daniel Borkmann <daniel@...earbox.net>,
Jiri Olsa <jolsa@...nel.org>, kernel-team@...com
Subject: Re: [PATCH bpf-next v2 3/5] bpf: add BTF_ID_LIST_GLOBAL in btf_ids.h
On Mon, Jul 20, 2020 at 09:34:01AM -0700, Yonghong Song wrote:
> 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@...com>
Acked-by: Jiri Olsa <jolsa@...hat.com>
jirka
Powered by blists - more mailing lists