Thread (19 messages) flat view 19 messages, 5 authors, 2026-01-06

Re: [PATCH bpf-next v6 00/10] bpf: fsession support

From: Alexei Starovoitov <hidden>
Date: 2026-01-05 22:33:50
Also in: bpf, lkml

On Sun, Jan 4, 2026 at 4:28 AM Menglong Dong [off-list ref] wrote:
In current solution, we can't reuse the existing bpf_session_cookie() and
bpf_session_is_return(), as their prototype is different from
bpf_fsession_is_return() and bpf_fsession_cookie(). In
bpf_fsession_cookie(), we need the function argument "void *ctx" to get
the cookie. However, the prototype of bpf_session_cookie() is "void".
I think it's ok to change proto to bpf_session_cookie(void *ctx)
for kprobe-session. It's not widely used yet, so proto change is ok
if it helps to simplify this tramp-session code.
I see that you adjust get_kfunc_ptr_arg_type(), so the verifier
will enforce PTR_TO_CTX for kprobe and trampoline.
Potentially can relax and enforce r1==ctx only for trampoline,
but I would do it for both for consistency.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help