From patchwork Wed Oct 4 20:38:12 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mat Martineau X-Patchwork-Id: 13409447 X-Patchwork-Delegate: kuba@kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5240B200AB; Wed, 4 Oct 2023 20:38:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="KaxzsuLv" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9C8FAC433CD; Wed, 4 Oct 2023 20:38:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1696451902; bh=7IsvQZm94ACVEELdVb0zhCa5ptfJqE0xG7ACha379Qg=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=KaxzsuLvLrkVf8rTUJ7meAERSenH/kiAEf1fX7UKrSoSn6PhEo6+1jBjFqSij1FbP wOFLvsSDiU0kPqCYrUi7a3vlLa1hfGfSHFRLrRE9TAW1Irn2L6xSdUHuZ70R+Sbndx Y8FIrOFv2/p9KCaIi7cWWSM3Og5GWub9k5jjtA07ZbwsjOrFAKtM+vZSMwBdbRhQdQ +3dPNUYsMcMDZlrk6RgTVy7uUqDzL5tIPKn1s9208qtTcnXo4DHHWVyn+E0s6LWRLg USR6m3tX7fEZ7p+RFkQD+ZZy4d0Uk+VnGR0Xc4uqH1bEyxTwM9wtmxu6docAPuAvN1 KMdFqSUsVEbdg== From: Mat Martineau Date: Wed, 04 Oct 2023 13:38:12 -0700 Subject: [PATCH net 2/3] mptcp: userspace pm allow creating id 0 subflow Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231004-send-net-20231004-v1-2-28de4ac663ae@kernel.org> References: <20231004-send-net-20231004-v1-0-28de4ac663ae@kernel.org> In-Reply-To: <20231004-send-net-20231004-v1-0-28de4ac663ae@kernel.org> To: Matthieu Baerts , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Matthieu Baerts Cc: netdev@vger.kernel.org, mptcp@lists.linux.dev, Kishen Maloor , Florian Westphal , Mat Martineau , Geliang Tang , stable@vger.kernel.org X-Mailer: b4 0.12.3 X-Patchwork-Delegate: kuba@kernel.org From: Geliang Tang This patch drops id 0 limitation in mptcp_nl_cmd_sf_create() to allow creating additional subflows with the local addr ID 0. There is no reason not to allow additional subflows from this local address: we should be able to create new subflows from the initial endpoint. This limitation was breaking fullmesh support from userspace. Fixes: 702c2f646d42 ("mptcp: netlink: allow userspace-driven subflow establishment") Closes: https://github.com/multipath-tcp/mptcp_net-next/issues/391 Cc: stable@vger.kernel.org Suggested-by: Matthieu Baerts Reviewed-by: Matthieu Baerts Signed-off-by: Geliang Tang Signed-off-by: Mat Martineau --- net/mptcp/pm_userspace.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/net/mptcp/pm_userspace.c b/net/mptcp/pm_userspace.c index b5a8aa4c1ebd..d042d32beb4d 100644 --- a/net/mptcp/pm_userspace.c +++ b/net/mptcp/pm_userspace.c @@ -307,12 +307,6 @@ int mptcp_nl_cmd_sf_create(struct sk_buff *skb, struct genl_info *info) goto create_err; } - if (addr_l.id == 0) { - NL_SET_ERR_MSG_ATTR(info->extack, laddr, "missing local addr id"); - err = -EINVAL; - goto create_err; - } - err = mptcp_pm_parse_addr(raddr, info, &addr_r); if (err < 0) { NL_SET_ERR_MSG_ATTR(info->extack, raddr, "error parsing remote addr");