On Fri, 9 Feb 2024 at 05:06, Alexei Starovoitov <alexei.starovoitov@xxxxxxxxx> wrote: > > From: Alexei Starovoitov <ast@xxxxxxxxxx> > > In global bpf functions recognize btf_decl_tag("arg:arena") as PTR_TO_ARENA. > > Note, when the verifier sees: > > __weak void foo(struct bar *p) > > it recognizes 'p' as PTR_TO_MEM and 'struct bar' has to be a struct with scalars. > Hence the only way to use arena pointers in global functions is to tag them with "arg:arena". > > Signed-off-by: Alexei Starovoitov <ast@xxxxxxxxxx> > --- Acked-by: Kumar Kartikeya Dwivedi <memxor@xxxxxxxxx>