On Thu, Jul 14, 2022 at 10:12 AM Indu Bhagat <indu.bhagat@xxxxxxxxxx> wrote: > > The vlen bits in the BTF type of kind BTF_KIND_FUNC are used to convey the > linkage information for functions. The Linux kernel only supports > linkage values of static (=0), and global (=1) at this time. > > Signed-off-by: Indu Bhagat <indu.bhagat@xxxxxxxxxx> > --- > Documentation/bpf/btf.rst | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/Documentation/bpf/btf.rst b/Documentation/bpf/btf.rst > index f49aeef62d0c..3f9cc9150c89 100644 > --- a/Documentation/bpf/btf.rst > +++ b/Documentation/bpf/btf.rst > @@ -369,7 +369,7 @@ No additional type data follow ``btf_type``. > * ``name_off``: offset to a valid C identifier > * ``info.kind_flag``: 0 > * ``info.kind``: BTF_KIND_FUNC > - * ``info.vlen``: 0 > + * ``info.vlen``: linkage information (static=0, global=1, extern=2) 0, 1, 2 are not arbitrary integers, those are enum btf_func_linkage, which is why I asked to mention that UAPI enum here > * ``type``: a BTF_KIND_FUNC_PROTO type > > No additional type data follow ``btf_type``. > @@ -380,6 +380,9 @@ type. The BTF_KIND_FUNC may in turn be referenced by a func_info in the > :ref:`BTF_Ext_Section` (ELF) or in the arguments to :ref:`BPF_Prog_Load` > (ABI). > > +Currently, only linkage values of static and global are supported in the > +kernel. > + > 2.2.13 BTF_KIND_FUNC_PROTO > ~~~~~~~~~~~~~~~~~~~~~~~~~~ > > -- > 2.31.1 >