Re: [PATCH bpf v1 0/4] bpf: Scope callback arguments to their frame

From: Alexei Starovoitov

Date: Thu Nov 12 2026 - 21:51:26 EST


On Fri Nov 6, 2026 at 11:32 PM UTC, Ihor Solodrai wrote:
> On 11/6/26 4:11 PM, Ihor Solodrai wrote:
>> [...]
>>
>> Ihor Solodrai (4):
>> bpf: Scope the bpf_user_ringbuf_drain() dynptr to its callback frame
>> selftests/bpf: Cover the user ringbuf callback dynptr lifetime
>> bpf: Scope the bpf_for_each_map_elem() array key to the callback frame
>> selftests/bpf: Cover callback-frame map key lifetime
>
> Alexei, if this lands first, your pending verifier rewrite will need a
> hunk like the one pasted below. Or the other way around.
>
> Without it, a join can link a value to the wrong callback frame.
>
> diff --git a/kernel/bpf/join.c b/kernel/bpf/join.c
> index cc4494aef187..92b94e18c873 100644
> --- a/kernel/bpf/join.c
> +++ b/kernel/bpf/join.c
> @@ -464,6 +464,9 @@ static bool join_func(struct bpf_join_state *js, struct bpf_func_state *fd,
> return false;
> if (!join_loop_stack(fa, fb))
> return false;
> + jid_note(js, fa->frame_id, fb->frame_id, true);
> + } else if (!jid_strict_ok(js, fa->frame_id, fb->frame_id)) {
> + return false;
> }

This and your other set no longer applies. Sorry.
Please respin them both as one set against bpf-next.

pw-bot: cr