Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp1348902pxf; Fri, 19 Mar 2021 05:25:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzxA43ojKIBLjJtmcwvmsBuDIuqzqvRvf1yuJekZBAosMLaLoxMrwhpRPnfG9n7pr+lSIDI X-Received: by 2002:a17:906:5a8f:: with SMTP id l15mr4050735ejq.462.1616156716639; Fri, 19 Mar 2021 05:25:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616156716; cv=none; d=google.com; s=arc-20160816; b=rbitlGODKbgY/TcWPcJWLElG9B/Xgd6gixeu7nQtQXdOWcwl+SLEyKrI962FiG9Zk4 +tzJmo7J5DQzLSf6tbfKWoy2VWRfZGcgXFaojHs8BKYnXzKXzMHk/L9YEFgn0LYQ4CYc mm5VL98HGODh2zWAqpLOieGenQMnUGGeh6kjgZFG9ZoAgIxCKRRQUVmZSpjzzOzeuwW4 F9k0249AGhbGZYX24jQU+IKRydd1sx+wq6ubLa4m6VrGWSfFIKsqg6yzMmnmqfd9Znje e8lRA3Sz91gFbnIdkSh6r3Nkf9XwzW1TMP1XPeZrtpYn4Vt5AszNaYEOat/MJAYJl2ln KhBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=qiAL3MVrrXoUnee0RFA1RQYj2pT6T4keFVVSwFNn1/8=; b=hbkWJJSbAfVlSkw/qjR9jb+MLpCnPP1cMVm4o6beA/kiNFl5UEfFnrEkh/KAzhAMFf ENSzthprLrWim4eVLwKm/cTwaoPZiwBaDvhMwDSR91mM/PfnNilO6Q2v58G0d4kAAzEz hmErWVg8VAEf7iVRvPpdsXkMYPz/30lne/KKRNMthaJIAn6bgLmik0tchSe0aAvlEpd4 Wp7f4bK/CknJGwKnw0HUlmOqT4qKINUHLtg+frjTLEaQQ+rwRFyViT0PUhHlFKf8+irg BmZQ+0OOOZlN0jBKGe16pJAMsOV3s2cs3JHHWgHWUioOfZZ7WLyYmsjSzs/hZyatq1wM mhcQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=oU8Aw7xU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f25si4030181edr.248.2021.03.19.05.24.54; Fri, 19 Mar 2021 05:25:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=oU8Aw7xU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231398AbhCSMV1 (ORCPT + 99 others); Fri, 19 Mar 2021 08:21:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:58996 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230527AbhCSMUr (ORCPT ); Fri, 19 Mar 2021 08:20:47 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 01C6964F6A; Fri, 19 Mar 2021 12:20:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1616156446; bh=js529rVkBkIZs0DCJLRCuffamEhj/InIOopjlbZe69s=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=oU8Aw7xUoLlvdfETmR1UcKyiCnuz70IvplUDZguni0qLDEeEnoJr6id1UX9uqeyPX nqbDtBEevIRz+rewWxX9mTvr7dIWkrk8GenOadWKZwCZl9shYT7cmelHRW1imiMPaO 3sviDA0eHAWkoW03Qq7kd8sWYCJcoAAV9GeEVPjI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Paolo Abeni , Geliang Tang , Mat Martineau , Jakub Kicinski , Sasha Levin Subject: [PATCH 5.11 04/31] mptcp: send ack for every add_addr Date: Fri, 19 Mar 2021 13:18:58 +0100 Message-Id: <20210319121747.349516748@linuxfoundation.org> X-Mailer: git-send-email 2.31.0 In-Reply-To: <20210319121747.203523570@linuxfoundation.org> References: <20210319121747.203523570@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Geliang Tang [ Upstream commit b5a7acd3bd63c7430c98d7f66d0aa457c9ccde30 ] This patch changes the sending ACK conditions for the ADD_ADDR, send an ACK packet for any ADD_ADDR, not just when ipv6 addresses or port numbers are included. Closes: https://github.com/multipath-tcp/mptcp_net-next/issues/139 Acked-by: Paolo Abeni Signed-off-by: Geliang Tang Signed-off-by: Mat Martineau Signed-off-by: Jakub Kicinski Signed-off-by: Sasha Levin --- net/mptcp/pm.c | 3 +-- net/mptcp/pm_netlink.c | 10 ++++------ 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/net/mptcp/pm.c b/net/mptcp/pm.c index da2ed576f289..5463d7c8c931 100644 --- a/net/mptcp/pm.c +++ b/net/mptcp/pm.c @@ -188,8 +188,7 @@ void mptcp_pm_add_addr_received(struct mptcp_sock *msk, void mptcp_pm_add_addr_send_ack(struct mptcp_sock *msk) { - if (!mptcp_pm_should_add_signal_ipv6(msk) && - !mptcp_pm_should_add_signal_port(msk)) + if (!mptcp_pm_should_add_signal(msk)) return; mptcp_pm_schedule_work(msk, MPTCP_PM_ADD_ADDR_SEND_ACK); diff --git a/net/mptcp/pm_netlink.c b/net/mptcp/pm_netlink.c index a6d983d80576..b81ce0ea1f8b 100644 --- a/net/mptcp/pm_netlink.c +++ b/net/mptcp/pm_netlink.c @@ -408,8 +408,7 @@ void mptcp_pm_nl_add_addr_send_ack(struct mptcp_sock *msk) { struct mptcp_subflow_context *subflow; - if (!mptcp_pm_should_add_signal_ipv6(msk) && - !mptcp_pm_should_add_signal_port(msk)) + if (!mptcp_pm_should_add_signal(msk)) return; __mptcp_flush_join_list(msk); @@ -419,10 +418,9 @@ void mptcp_pm_nl_add_addr_send_ack(struct mptcp_sock *msk) u8 add_addr; spin_unlock_bh(&msk->pm.lock); - if (mptcp_pm_should_add_signal_ipv6(msk)) - pr_debug("send ack for add_addr6"); - if (mptcp_pm_should_add_signal_port(msk)) - pr_debug("send ack for add_addr_port"); + pr_debug("send ack for add_addr%s%s", + mptcp_pm_should_add_signal_ipv6(msk) ? " [ipv6]" : "", + mptcp_pm_should_add_signal_port(msk) ? " [port]" : ""); lock_sock(ssk); tcp_send_ack(ssk); -- 2.30.1