Received: by 2002:a05:6358:5282:b0:b5:90e7:25cb with SMTP id g2csp3248852rwa; Tue, 23 Aug 2022 01:07:47 -0700 (PDT) X-Google-Smtp-Source: AA6agR6zjzMGL+QjX1zVZlGxV8ay7bwPYJcIqH71ZWLmBi9+tf1IZlhqubqp4SyJBC0GVKZLg7K4 X-Received: by 2002:a05:6a00:1681:b0:52e:d9b1:8596 with SMTP id k1-20020a056a00168100b0052ed9b18596mr24261924pfc.56.1661242067631; Tue, 23 Aug 2022 01:07:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661242067; cv=none; d=google.com; s=arc-20160816; b=owVMJMn08HtRgpssSlSZGM1NGn0DEluKf0T+8HX4jUcg04sefSTlhXloVVNNAIJF1L eL6YLd8INbP8JWgMwXTCys5ggdpmIqz43GlzHHyA/jrrHSS7Cr+XfzfJlURB7QTWwCuo VOWwdH4qsRZ/FFARuG/6RQwYwAXPbnDuRWLLUKe9TRrLfv7j2QDZ7D7V7uIQneefnZAI 1WrQHF+KihrMF1cgbcA9oVfuaC7+zLmxOaKeY9GmsUbqVta2sv3OgzSMXZptrdgLmPWH eVe7Hkplt4/KGIm4Qfk36Fu1HjcYH9R/l1tFdYmqaM7yKJB7GCTS0GxkEj7CfLM5CGt9 hW+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:message-id:user-agent :references:in-reply-to:subject:cc:to:from:date:mime-version; bh=xRHY0UwOCd3ykJFPRZpExBF6abaInBKtPxnkyAVmVRE=; b=GVyPmtmi3ygLdD6+QTnZdv7+5N/EL54FCYI1i2Y0k/V+i/YtCKBBKVbtJsO882jZEi /JDAj1gA3bf22hV1XqRk6wYfhhizuWsWvfUJG6CX2JHN7kcRPKGH7MOnLcKdUCvCaiuz QB1JpiTK/Ntb7OeP94NJ3coNgRRFDNQI+8IsTGo6P4+PC8eVslS2BfaEOFU8AgxXyr86 D/980L/8pwYHDPffw6Ks+URxkKHN4/z+/sKk3EhD08MLlsOJKNkzmAUf5UIt5lzI9VZR lLS9e5ysjyGJlcKbF2bO7qjKi2gWOTNx4/a2srSLKlhcAjKdNWc6vLissUVeqsXVaC/f Kv+w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a3-20020a1709027e4300b0016ee3f481a1si12989026pln.304.2022.08.23.01.07.35; Tue, 23 Aug 2022 01:07:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240873AbiHWHiA (ORCPT + 99 others); Tue, 23 Aug 2022 03:38:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45910 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240083AbiHWHh6 (ORCPT ); Tue, 23 Aug 2022 03:37:58 -0400 Received: from mailout-taastrup.gigahost.dk (mailout-taastrup.gigahost.dk [46.183.139.199]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 58FC9642F8; Tue, 23 Aug 2022 00:37:56 -0700 (PDT) Received: from mailout.gigahost.dk (mailout.gigahost.dk [89.186.169.112]) by mailout-taastrup.gigahost.dk (Postfix) with ESMTP id B7DBF1884AE4; Tue, 23 Aug 2022 07:37:54 +0000 (UTC) Received: from smtp.gigahost.dk (smtp.gigahost.dk [89.186.169.109]) by mailout.gigahost.dk (Postfix) with ESMTP id AE68E25032BA; Tue, 23 Aug 2022 07:37:54 +0000 (UTC) Received: by smtp.gigahost.dk (Postfix, from userid 1000) id 86C83A1A0060; Tue, 23 Aug 2022 07:37:54 +0000 (UTC) X-Screener-Id: 413d8c6ce5bf6eab4824d0abaab02863e8e3f662 MIME-Version: 1.0 Date: Tue, 23 Aug 2022 09:37:54 +0200 From: netdev@kapio-technology.com To: Ido Schimmel Cc: Vladimir Oltean , davem@davemloft.net, kuba@kernel.org, netdev@vger.kernel.org, Andrew Lunn , Vivien Didelot , Florian Fainelli , Eric Dumazet , Paolo Abeni , Jiri Pirko , Ivan Vecera , Roopa Prabhu , Nikolay Aleksandrov , Shuah Khan , Daniel Borkmann , linux-kernel@vger.kernel.org, bridge@lists.linux-foundation.org, linux-kselftest@vger.kernel.org Subject: Re: [PATCH v4 net-next 3/6] drivers: net: dsa: add locked fdb entry flag to drivers In-Reply-To: References: <5a4cfc6246f621d006af69d4d1f61ed1@kapio-technology.com> <34dd1318a878494e7ab595f8727c7d7d@kapio-technology.com> <9dcb4db4a77811308c56fe5b9b7c5257@kapio-technology.com> User-Agent: Gigahost Webmail Message-ID: <553c573ad6a2ddfccfc47c7847cc5fb7@kapio-technology.com> X-Sender: netdev@kapio-technology.com Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2022-08-23 09:24, Ido Schimmel wrote: > On Tue, Aug 23, 2022 at 09:13:54AM +0200, netdev@kapio-technology.com > wrote: >> On 2022-08-23 08:48, Ido Schimmel wrote: >> > On Mon, Aug 22, 2022 at 09:49:28AM +0200, netdev@kapio-technology.com >> > wrote: >> >> > > As I am not familiar with roaming in this context, I need to know >> > > how the SW >> > > bridge should behave in this case. >> > >> >> > > In this case, is the roaming only between locked ports or does the >> > > roaming include that the entry can move to a unlocked port, resulting >> > > in the locked flag getting removed? >> > >> > Any two ports. If the "locked" entry in mv88e6xxx cannot move once >> > installed, then the "sticky" flag accurately describes it. >> > >> >> But since I am also doing the SW bridge implementation without >> mv88e6xxx I >> need it to function according to needs. >> Thus the locked entries created in the bridge I shall not put the >> sticky >> flag on, but there will be the situation where a locked entry can move >> to an >> unlocked port, which we regarded as a bug. > > I do not regard this as a bug. It makes sense to me that an authorized > port can cause an entry pointing to an unauthorized port to roam to > itself. Just like normal learned entries. What I considered as a bug is > the fact that the "locked" flag is not cleared when roaming to an > authorized port. > >> In that case there is two possibilities, the locked entry can move to >> an unlocked port with the locked flag being removed or the locked >> entry can only move to another locked port? > > My suggestion is to allow roaming and maintain / clear the "locked" > flag > based on whether the new destination port is locked or not. Thus I understand it as saying that the "locked" flag can also be set when roaming from an unlocked port to a locked port?