This is the needed refactor for the selinux fixes, as discussed on
the ML.
The main change, introduced by patch 6/9 consist in moving the first
subflow initialization from the msk init callback into the mptcp
syscall needing such data (namely: bind, listen, connect).
Patch 4 and 5 allow making such change smaller.
Patches 7, 8, 9 are not strictly needed, but are some nice to have
follow-up, cleaning-up the related code.
Specifically patch 8 closes issues/290, but requires some additional
pre-req (patches 1-3), which in turn are also nice to have IMHO.
Sharing after little testing to get feedback and let the bot massage
the new code: patch 1 and 7 can have subtle effect, I would like to
have syzkaller digest them for a while.
I'll rebase the selinux patches on top and share them soon.
Paolo Abeni (9):
mptcp: refactor passive socket initialization.
mptcp: drop unneeded argument
mptcp: drop legacy code.
mptcp: avoid unneeded __mptcp_nmpc_socket() usage
mptcp: move fastopen subflow check inside mptcp_sendmsg_fastopen()
mptcp: move first subflow allocation at mpc access time
mptcp: do not keep around the first subflow after disconnect.
mptcp: fastclose msk when cleaning unaccepted sockets
mptcp: refactor mptcp_stream_accept()
net/mptcp/options.c | 9 +--
net/mptcp/pm.c | 4 +-
net/mptcp/pm_netlink.c | 4 +-
net/mptcp/protocol.c | 159 ++++++++++++++++++++++-------------------
net/mptcp/protocol.h | 4 +-
net/mptcp/sockopt.c | 18 ++---
net/mptcp/subflow.c | 40 +++++++----
7 files changed, 132 insertions(+), 106 deletions(-)
--
2.38.1