From nobody Mon Feb 9 08:56:43 2026 Delivered-To: wpasupplicant.patchew@gmail.com Received: by 2002:a02:cbb9:0:0:0:0:0 with SMTP id v25csp1110709jap; Fri, 3 Dec 2021 14:36:01 -0800 (PST) X-Google-Smtp-Source: ABdhPJzCGdv1urUNIJ9uXgRDdlbBkE/b6yRdvwsI97XiKusa/NVuzh5NebQeaRx2qGXcLLv8kl+N X-Received: by 2002:a17:903:120a:b0:143:e4e9:4cdb with SMTP id l10-20020a170903120a00b00143e4e94cdbmr25591197plh.89.1638570961631; Fri, 03 Dec 2021 14:36:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1638570961; cv=none; d=google.com; s=arc-20160816; b=xTcyL83bmBM18O9P6q6inZkHO7D0lGtixhSC53OvMVawlFT0m7nL/7jHZPiGu9qMS2 Ktg7SGQPBs+N5eka20K9+p4yyUwxIRrSbVCWW5S9QqDwg+g394SiGwDIMmim22xoz+Dn Yc71hHxTlOJypZj2ZYEDSK/3v7q47CtHmj+IDaATRqinnVEaD5uPyckrpKRNQxntx1BQ ffoi1PyEpjL8sXidpmcNTjeVVbfBgnt48xa8abc19IzWsQO7rjy7NpIxkS8sT88Gr0Sz B2E4nQlXQHOx43PqVFFcoBLE5NaKJ3IPmnao4fAahQLde2M+8BNd42hzU6Q+vAvqusdC F2Zw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from; bh=oWlNhohRGw5dW113tIGW5jGGroT6imNAlorwwc3FQnI=; b=sg/J35D0CIrx5OUSCEY8usR9UtmGHKkgQ0ZqvrosWuBodt6uXtPvBHglOKuJeq3gA/ CSMYK92zFUxz5blwt6LNyIa2lcVQVf2/v9BkI8ux0gGRey36gEyF2+xFcFj4S2CxKvy9 rO7FfvNIt4uaDsAOHkxppfItwRGlRKaG5W89BwII5N96Wcm3bQRyde0lavFnr/6qIrxS 0D/JX2P9vnHGNo0UhJzNHCMsmdF4hIZ2mnX+LnKzwoGX2TXzYFf/QVMx0GBOnJyrUIKS 8K9fJGmNF7cjEbpq5+bdqHs1nm/NmDK1bWwV7hUmA8wPkBO31qWC/BDnGwS/pZ8Lk+45 3l9g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of mptcp+bounces-2633-wpasupplicant.patchew=gmail.com@lists.linux.dev designates 147.75.69.165 as permitted sender) smtp.mailfrom="mptcp+bounces-2633-wpasupplicant.patchew=gmail.com@lists.linux.dev"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from sjc.edge.kernel.org (sjc.edge.kernel.org. [147.75.69.165]) by mx.google.com with ESMTPS id qe16si5748465pjb.189.2021.12.03.14.36.01 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 03 Dec 2021 14:36:01 -0800 (PST) Received-SPF: pass (google.com: domain of mptcp+bounces-2633-wpasupplicant.patchew=gmail.com@lists.linux.dev designates 147.75.69.165 as permitted sender) client-ip=147.75.69.165; Authentication-Results: mx.google.com; spf=pass (google.com: domain of mptcp+bounces-2633-wpasupplicant.patchew=gmail.com@lists.linux.dev designates 147.75.69.165 as permitted sender) smtp.mailfrom="mptcp+bounces-2633-wpasupplicant.patchew=gmail.com@lists.linux.dev"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sjc.edge.kernel.org (Postfix) with ESMTPS id 373223E0FF2 for ; Fri, 3 Dec 2021 22:36:01 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 83D4F2CB0; Fri, 3 Dec 2021 22:35:53 +0000 (UTC) X-Original-To: mptcp@lists.linux.dev Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) (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 8E7512C9D for ; Fri, 3 Dec 2021 22:35:52 +0000 (UTC) X-IronPort-AV: E=McAfee;i="6200,9189,10187"; a="235802949" X-IronPort-AV: E=Sophos;i="5.87,284,1631602800"; d="scan'208";a="235802949" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Dec 2021 14:35:48 -0800 X-IronPort-AV: E=Sophos;i="5.87,284,1631602800"; d="scan'208";a="460185314" Received: from mjmartin-desk2.amr.corp.intel.com (HELO mjmartin-desk2.intel.com) ([10.251.18.88]) by orsmga003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Dec 2021 14:35:47 -0800 From: Mat Martineau To: netdev@vger.kernel.org Cc: Maxim Galaganov , davem@davemloft.net, kuba@kernel.org, matthieu.baerts@tessares.net, mptcp@lists.linux.dev, Paolo Abeni , Mat Martineau Subject: [PATCH net-next 09/10] mptcp: expose mptcp_check_and_set_pending Date: Fri, 3 Dec 2021 14:35:40 -0800 Message-Id: <20211203223541.69364-10-mathew.j.martineau@linux.intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20211203223541.69364-1-mathew.j.martineau@linux.intel.com> References: <20211203223541.69364-1-mathew.j.martineau@linux.intel.com> Precedence: bulk X-Mailing-List: mptcp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" From: Maxim Galaganov Expose the mptcp_check_and_set_pending() function for use inside MPTCP sockopt code. The next patch will call it when TCP_CORK is cleared or TCP_NODELAY is set on the MPTCP socket in order to push pending data from mptcp_release_cb(). Acked-by: Paolo Abeni Reviewed-by: Matthieu Baerts Signed-off-by: Maxim Galaganov Signed-off-by: Mat Martineau --- net/mptcp/protocol.c | 2 +- net/mptcp/protocol.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c index 943f74e804bd..f124cca125d2 100644 --- a/net/mptcp/protocol.c +++ b/net/mptcp/protocol.c @@ -1502,7 +1502,7 @@ static void mptcp_update_post_push(struct mptcp_sock = *msk, msk->snd_nxt =3D snd_nxt_new; } =20 -static void mptcp_check_and_set_pending(struct sock *sk) +void mptcp_check_and_set_pending(struct sock *sk) { if (mptcp_send_head(sk) && !test_bit(MPTCP_PUSH_PENDING, &mptcp_sk(sk)->flags)) diff --git a/net/mptcp/protocol.h b/net/mptcp/protocol.h index bb51fa7f5566..147b22da41ca 100644 --- a/net/mptcp/protocol.h +++ b/net/mptcp/protocol.h @@ -555,6 +555,7 @@ unsigned int mptcp_stale_loss_cnt(const struct net *net= ); void mptcp_subflow_fully_established(struct mptcp_subflow_context *subflow, struct mptcp_options_received *mp_opt); bool __mptcp_retransmit_pending_data(struct sock *sk); +void mptcp_check_and_set_pending(struct sock *sk); void __mptcp_push_pending(struct sock *sk, unsigned int flags); bool mptcp_subflow_data_available(struct sock *sk); void __init mptcp_subflow_init(void); --=20 2.34.1