diff options
| author | Eric Dumazet <edumazet@google.com> | 2025-08-26 13:44:35 +0000 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-09-04 15:31:51 +0200 |
| commit | d2d08fc3577f11eaeb2981d53122a3d280e49bfa (patch) | |
| tree | eee15dfff858656fd71e15ee88eb442bb34eceb8 /include/net/aligned_data.h | |
| parent | 1bbc0c02aea1f1c405bd1271466889c25a1fe01b (diff) | |
l2tp: do not use sock_hold() in pppol2tp_session_get_sock()
[ Upstream commit 9b8c88f875c04d4cb9111bd5dd9291c7e9691bf5 ]
pppol2tp_session_get_sock() is using RCU, it must be ready
for sk_refcnt being zero.
Commit ee40fb2e1eb5 ("l2tp: protect sock pointer of
struct pppol2tp_session with RCU") was correct because it
had a call_rcu(..., pppol2tp_put_sk) which was later removed in blamed commit.
pppol2tp_recv() can use pppol2tp_session_get_sock() as well.
Fixes: c5cbaef992d6 ("l2tp: refactor ppp socket/session relationship")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: James Chapman <jchapman@katalix.com>
Reviewed-by: Guillaume Nault <gnault@redhat.com>
Link: https://patch.msgid.link/20250826134435.1683435-1-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include/net/aligned_data.h')
0 files changed, 0 insertions, 0 deletions
