]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
mptcp: remove MPC && MPJ check
authorMatthieu Baerts (NGI0) <matttbe@kernel.org>
Mon, 3 Aug 2026 16:16:35 +0000 (18:16 +0200)
committerJakub Kicinski <kuba@kernel.org>
Thu, 6 Aug 2026 15:46:23 +0000 (08:46 -0700)
After the parent commit ("mptcp: avoid combining some incoming
suboptions"), the parsing step no longer allow to have both the
MP_CAPABLE and MP_JOIN suboptions set together.

These chunks are now unreachable, these checks can then be removed.

Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Link: https://patch.msgid.link/20260803-net-mptcp-misc-fixes-7-2-rc6-v2-3-b8f496d71664@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/mptcp/subflow.c

index 8e386899ceb98052e7e0612e0bb4bf8b4459d463..e1f20ff8fdb4245bdaa95757c18798b4798b7acd 100644 (file)
@@ -174,8 +174,6 @@ static int subflow_check_req(struct request_sock *req,
 
                if (unlikely(listener->pm_listener))
                        return subflow_reset_req_endp(req, skb);
-               if (opt_mp_join)
-                       return 0;
        } else if (opt_mp_join) {
                SUBFLOW_REQ_INC_STATS(req, MPTCP_MIB_JOINSYNRX);
 
@@ -277,9 +275,6 @@ int mptcp_subflow_init_cookie_req(struct request_sock *req,
 
        opt_mp_capable = !!(mp_opt.suboptions & OPTION_MPTCP_MPC_ACK);
        opt_mp_join = !!(mp_opt.suboptions & OPTION_MPTCP_MPJ_ACK);
-       if (opt_mp_capable && opt_mp_join)
-               return -EINVAL;
-
        if (opt_mp_capable && listener->request_mptcp) {
                if (mp_opt.sndr_key == 0)
                        return -EINVAL;