Re: [PATCH bpf-next v5 01/10] bpf: add fsession support

From: Jiri Olsa
Date: Fri Jan 02 2026 - 07:13:21 EST


On Fri, Jan 02, 2026 at 05:21:42PM +0800, Menglong Dong wrote:

SNIP

> > ---
> > diff --git a/include/linux/bpf.h b/include/linux/bpf.h
> > index 4e7d72dfbcd4..7479664844ea 100644
> > --- a/include/linux/bpf.h
> > +++ b/include/linux/bpf.h
> > @@ -1309,6 +1309,7 @@ enum bpf_tramp_prog_type {
> > BPF_TRAMP_MODIFY_RETURN,
> > BPF_TRAMP_MAX,
> > BPF_TRAMP_REPLACE, /* more than MAX */
> > + BPF_TRAMP_FSESSION,
> > };
> >
> > struct bpf_tramp_image {
> > @@ -1861,6 +1862,7 @@ struct bpf_link_ops {
> > struct bpf_tramp_link {
> > struct bpf_link link;
> > struct hlist_node tramp_hlist;
> > + struct hlist_node extra_hlist;
> > u64 cookie;
> > };
>
> In this way, it indeed can make the update of the hlist more clear. However,
> I think that you missed the reading of the hlist as I mentioned above.
> You can't add both the "tramp_hlist" and "extra_hlist" to the same hlist. If
> so, how do we iterate the hlist? Do I miss something?

ugh, it's on the same list.. nevermind then ;-)

jirka