Re: [PATCH net v3] tcp: clear sock_ops cb flags before force-closing a child socket
From: patchwork-bot+netdevbpf
Date: Fri Jun 12 2026 - 19:50:21 EST
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@xxxxxxxxxx>:
On Thu, 11 Jun 2026 09:29:18 +0000 you wrote:
> A child socket inherits the listener's bpf_sock_ops_cb_flags via
> sk_clone_lock(). If its setup fails in tcp_v4_syn_recv_sock() /
> tcp_v6_syn_recv_sock(), the child is freed through put_and_exit, where
> inet_csk_prepare_forced_close() drops the socket lock and tcp_done() runs
> without it.
>
> If BPF_SOCK_OPS_STATE_CB_FLAG was inherited, tcp_done() -> tcp_set_state()
> calls tcp_call_bpf(), which expects the lock and trips sock_owned_by_me():
>
> [...]
Here is the summary with links:
- [net,v3] tcp: clear sock_ops cb flags before force-closing a child socket
https://git.kernel.org/netdev/net/c/990348e5bb45
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html