Received: by 2002:ab2:3350:0:b0:1f4:6588:b3a7 with SMTP id o16csp481311lqe; Sat, 6 Apr 2024 09:04:16 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCW+robpDOShNjSiShV7VSVQhQwMRgCh75k3RJGnNAZLwL0Q9E0oaZkMeUpL36viKWFdo2WGWTdKyFKutrvsdQsbOBDVGMhm5x9vZfVXeA== X-Google-Smtp-Source: AGHT+IG4dhatFe/j5L/y5F0EIiarGRufoBJzASKt5ciSj3CSG5KD6ZhhdtC0XcbbJMbfvxRAIcT4 X-Received: by 2002:a05:6a00:98c:b0:6e6:9942:fd97 with SMTP id u12-20020a056a00098c00b006e69942fd97mr6169077pfg.15.1712419455793; Sat, 06 Apr 2024 09:04:15 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712419455; cv=pass; d=google.com; s=arc-20160816; b=nsKc+ZxMwuunUQozk98a5Bvqni7VRoPbIakbe1wQJxhfituHtEWOOR+khe06Bnz7Mo up7+4TTns86BfP2Z2foYRr/W0OFzwOjTfn/SJR0HQO2oSDFCNq5yr4q3nXnE7r0gv4Kf SpeAskyuZUpajtvW+KEkvEtfR65F0tVhII9gLYCqxyA+RDm59VyxfK4sWUmK/2r6OG0S Z5T1Wdx4dBfsvm+pXE9WL8eZXJpwj3kpfGNI0Qj42IsdVwJ/5l2oj/5WyropJjjIGYk5 Qbc68fY8DsWwGB+nlfhnpHSoXfLi6YvTgnmzzUjS+WRNd43fV+9pZEfWV2SprNB+BVYk fIkg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=aoqBFMPtv06Tsodf8p8KxXpEEQPVA8uVD5ySTvOXHfU=; fh=1RLVn8ATMBBH1X5J1Ff5/vC9cEUAsYePT41Z0b1iGRw=; b=t6X8UkuR+Mw6zePIZPnByy9z65SsgkPiGBqVHeA9SreTpwEoEE0jtCHvWn+SqGwJ7O yKmHomOFPRjxaphwzQsrskeXxcTqSYuxt2Q/+9iHuHTpWjkqLJcFx4bL+CTDflA3UFHj 0saGV4BllfHAQKTaPKi92cuzT1bPzKDAAlRJ8I9bgCtZ9CoEkE7uX8Bi8F+Dgx1nNsvw e1LZr+33wWmzDCp21zlqClFslFs/fWyONBfUU+jY5JTWVlrze9WX9vuxDlV3JmzG0Ozt fj2Q3D9H1F1IMAq4sd2KeMgc6X8TCBjjWW/ZgUYoiZK4doQFw/shq+FuGVP7IliLoMAy sa2A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=jweD7ZXv; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-133997-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-133997-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id z3-20020aa79e43000000b006eabaeda14asi3287109pfq.387.2024.04.06.09.04.15 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 06 Apr 2024 09:04:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-133997-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=jweD7ZXv; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-133997-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-133997-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org 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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 24B43B213BE for ; Sat, 6 Apr 2024 16:04:13 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id CC89C3BBF4; Sat, 6 Apr 2024 16:04:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="jweD7ZXv" 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 03B7C2943F; Sat, 6 Apr 2024 16:04:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712419441; cv=none; b=Alz76nlO3r5h7Iu/j/VZB+Bt34CSuCfsi9cFjbsOagWHSbVi8rt4dWdTSxSPrhpxn3l5EXVwbv+Ci2zsfXAFm8fv46Jm3WN1T3xI9rjfbPtPhjXkW8p3z47vwg5DwETGWJW+trRRTU2e/4+kIp3/GvEpEmc79MBmkdsJRFM4ZZ4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712419441; c=relaxed/simple; bh=2INVDo7T/+YeVJ1P5sAhixC0o7iVfIgS+M5BX7Wim/8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=arudpzQiPedH/RB088PwAD/MlIChp9pYdvjILAISEPXuKkhNhFDA3A/n55/edimHYwx/FhVdsCyv8yQNLuZPbCU3kGLs5GHkq/n6eM2pJrNdLQ992gMqDLqTpXA2p4frzNFN4MQSv0f5MonxqN7k1Nf2lKBPYKfIMo2NqciojQM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=jweD7ZXv; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 129E2C433C7; Sat, 6 Apr 2024 16:03:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1712419440; bh=2INVDo7T/+YeVJ1P5sAhixC0o7iVfIgS+M5BX7Wim/8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=jweD7ZXv2QxoMo4HV+/UBhjNMw4XKjD1qbw3n6VTeM2TZJWO3iRUpAlnlGy9GwktG UNZ2HvkIgrKuumLMPr66XuG7TtI72lngK+A+xfyEo4GkAwS3YsMFfPMEZ7Zfk67mE9 epOC2cWFtpSmW0aaoCu9n+kDpyCRprxEgFkKggm2TL3T48lo+HvsoIksV51F8iK5S8 EAMLv7MZrtQteBDkvKfcML6h7XuHBGzSBjd2f8tVK58B1cipo/du4L1JrnnE99raQZ zXB0VxWJFarVjwfCeiFuQMdS5XW4vuWstyuxfvCtTWBsyerBZ4q7KxE8eI49uQPtd4 VL8jMqM/CHDsg== Date: Sat, 6 Apr 2024 17:03:54 +0100 From: Simon Horman To: Thomas Bogendoerfer Cc: Jay Vosburgh , Andy Gospodarek , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH net] bonding: 802.3ad: Avoid packet loss when switching aggregator Message-ID: <20240406160354.GW26556@kernel.org> References: <20240404114908.134034-1-tbogendoerfer@suse.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240404114908.134034-1-tbogendoerfer@suse.de> On Thu, Apr 04, 2024 at 01:49:08PM +0200, Thomas Bogendoerfer wrote: > If selection logic decides to switch to a new aggregator it disables > all ports of the old aggregator, but doesn't enable ports on > the new aggregator. These ports will eventually be enabled when > the next LACPDU is received, which might take some time and without an > active port transmitted frames are dropped. Avoid this by enabling > already collected ports of the new aggregator immediately. > > Signed-off-by: Thomas Bogendoerfer Hi Thomas, I will leave the technical review to Jay and others. But as a fix, I think this patch warrants a Fixes tag. It should be sufficient to respond to this email thread with an appropriate tag. > --- > drivers/net/bonding/bond_3ad.c | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/drivers/net/bonding/bond_3ad.c b/drivers/net/bonding/bond_3ad.c > index c6807e473ab7..529e2a7c51e2 100644 > --- a/drivers/net/bonding/bond_3ad.c > +++ b/drivers/net/bonding/bond_3ad.c > @@ -1876,6 +1876,13 @@ static void ad_agg_selection_logic(struct aggregator *agg, > __disable_port(port); > } > } > + > + /* enable ports on new active aggregator */ > + for (port = best->lag_ports; port; > + port = port->next_port_in_aggregator) { > + __enable_port(port); > + } > + > /* Slave array needs update. */ > *update_slave_arr = true; > } > -- > 2.35.3 > >