Skip to contentSkip to conversation

bpf: preserve sleepable bit in subprog info

PATCH Applied Andrii Nakryiko 3 participants 3 messages Mar 14, 2024 – Mar 15, 2024

Subsystems (2)
lore
Share & tools
lore

Andrii Nakryiko

author maintainer
#0 lore raw

PATCH 1/1 bpf: preserve sleepable bit in subprog info

Copy over main program's sleepable bit into subprog's info. This might be important for, e.g., freplace cases.

---
 kernel/bpf/verifier.c | 1 +
 1 file changed, 1 insertion(+)
kernel/bpf/verifier.c +1 -0
index 63749ad5ac6b..7b208e5d38f6 100644
@@ -19158,6 +19158,7 @@ static int jit_subprogs(struct bpf_verifier_env *env)
 		if (bpf_prog_calc_tag(func[i]))
 			goto out_free;
 		func[i]->is_func = 1;
+		func[i]->sleepable = prog->sleepable;
 		func[i]->aux->func_idx = i;
 		/* Below members will be freed only at prog->aux */
 		func[i]->aux->btf = prog->aux->btf;
Signature · 1 line
2.43.0
#2 lore raw
In reply to Andrii Nakryiko
This patch was applied to bpf/bpf-next.git (master) by Alexei Starovoitov <[email protected]>:

Hello:

This patch was applied to bpf/bpf-next.git (master) by Alexei Starovoitov <[email protected]>:

Quoted 8 lines · On Wed, 13 Mar 2024 17:01:27 -0700 you wrote:

Copy over main program's sleepable bit into subprog's info. This might be important for, e.g., freplace cases.

---
 kernel/bpf/verifier.c | 1 +
 1 file changed, 1 insertion(+)

Here is the summary with links:
- [bpf-next] bpf: preserve sleepable bit in subprog info

    https://git.kernel.org/bpf/bpf-next/c/4d8926a0407c

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html