]> www.infradead.org Git - users/jedix/linux-maple.git/commit
Merge branch 'l2tp-session-cleanup' into main
authorDavid S. Miller <davem@davemloft.net>
Wed, 31 Jul 2024 08:25:14 +0000 (09:25 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 31 Jul 2024 08:25:14 +0000 (09:25 +0100)
commit3fafd92edbeb523bad6aa63ab7118112d533c9ec
tree4b6808fe72a0685580f8e7b0e12d050b3d8a991c
parent0a658d088cc63745528cf0ec8a2c2df0f37742d9
parent5dfa598b249c5bd8fa620843cf9ece1ad16929d9
Merge branch 'l2tp-session-cleanup' into main

James Chapman says:

====================
l2tp: simplify tunnel and session cleanup

This series simplifies and improves l2tp tunnel and session cleanup.

 * refactor l2tp management code to not use the tunnel socket's
   sk_user_data. This allows the tunnel and its socket to be closed
   and freed without sequencing the two using the socket's sk_destruct
   hook.

 * export ip_flush_pending_frames and use it when closing l2tp_ip
   sockets.

 * move the work of closing all sessions in the tunnel to the work
   queue so that sessions are deleted using the same codepath whether
   they are closed by user API request or their parent tunnel is
   closing.

 * refactor l2tp_ppp pppox socket / session relationship to have the
   session keep the socket alive, not the other way around. Previously
   the pppox socket held a ref on the session, which complicated
   session delete by having to go through the pppox socket destructor.

 * free sessions and pppox sockets by rcu.

 * fix a possible tunnel refcount underflow.

 * avoid using rcu_barrier in net exit handler.
====================

Signed-off-by: David S. Miller <davem@davemloft.net>