From patchwork Wed Oct 25 23:37:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mat Martineau X-Patchwork-Id: 13436966 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 B930A381C9; Wed, 25 Oct 2023 23:37:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="NfnDFh29" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7242AC433D9; Wed, 25 Oct 2023 23:37:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1698277033; bh=14cp60kxcA5TVRPTGt8VB60tSh4oksh/vqRJXjj+jbY=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=NfnDFh29/lHX0BPfEhKUwJ8adq4UjmBRIPZoOGX+f10umDk+V+XzRX0VWGLRII3d4 k6qrOWSUkZx3pssac70sGtp4/QufTYZgmJ7UQemm9zeOwizX5kFD97dmq6u7U4ieHJ E6vu/1m3WcmRCshN9NybAY9veSUEg14td2Nc8pHeuGkOc+bQnXq0NylUbVLKfJe+Go 5ZwMueWKXFBVjGFhlclYCOQUoxIQQx+wXE8uk++HUGykNazA0y8GuYgjV0DfkSqOHJ Cxt19Psl4i/ukk86QRSaLGQ4gCnmjb1Q869Brk02uq6OpSkPNfCjpdo613++uvnEvC H9971ptOop2jQ== From: Mat Martineau Date: Wed, 25 Oct 2023 16:37:07 -0700 Subject: [PATCH net-next 06/10] mptcp: use mptcp_get_ext helper Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231025-send-net-next-20231025-v1-6-db8f25f798eb@kernel.org> References: <20231025-send-net-next-20231025-v1-0-db8f25f798eb@kernel.org> In-Reply-To: <20231025-send-net-next-20231025-v1-0-db8f25f798eb@kernel.org> To: Matthieu Baerts , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Geliang Tang , Kishen Maloor Cc: netdev@vger.kernel.org, mptcp@lists.linux.dev, Mat Martineau X-Mailer: b4 0.12.4 X-Patchwork-Delegate: kuba@kernel.org From: Geliang Tang Use mptcp_get_ext() helper defined in protocol.h instead of open-coding it in mptcp_sendmsg_frag(). Reviewed-by: Matthieu Baerts Signed-off-by: Geliang Tang Signed-off-by: Mat Martineau --- net/mptcp/protocol.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c index a29116eda30a..a0b8356cd8c5 100644 --- a/net/mptcp/protocol.c +++ b/net/mptcp/protocol.c @@ -1267,7 +1267,7 @@ static int mptcp_sendmsg_frag(struct sock *sk, struct sock *ssk, * queue management operation, to avoid breaking the ext <-> * SSN association set here */ - mpext = skb_ext_find(skb, SKB_EXT_MPTCP); + mpext = mptcp_get_ext(skb); if (!mptcp_skb_can_collapse_to(data_seq, skb, mpext)) { TCP_SKB_CB(skb)->eor = 1; goto alloc_skb; @@ -1289,7 +1289,7 @@ static int mptcp_sendmsg_frag(struct sock *sk, struct sock *ssk, i = skb_shinfo(skb)->nr_frags; reuse_skb = false; - mpext = skb_ext_find(skb, SKB_EXT_MPTCP); + mpext = mptcp_get_ext(skb); } /* Zero window and all data acked? Probe. */