Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp1905838pxb; Wed, 9 Feb 2022 07:04:28 -0800 (PST) X-Google-Smtp-Source: ABdhPJzwy6U9bk6GJT5Li0hGm1OsSXjugein2/z0LUHKMU7hETpEyZE1EdxTyXEaQx3JGJctX9n/ X-Received: by 2002:a05:6402:5cb:: with SMTP id n11mr2938520edx.399.1644419066581; Wed, 09 Feb 2022 07:04:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644419066; cv=none; d=google.com; s=arc-20160816; b=e+pceXb4ArmNXzTtC3DWd7OUeJNaAP3qNV9omxTL92q8UzhZbHcEnEjkjCKMYD53L5 oSkFpOMBymCFdaCnwhJmtsTD7BDFb8843SJE56sGaZMxM1KsH/Lcpckz/EHIpWhPGD2p 5VIUZB6j+Rs20JxlOllBKsRKwEVterNS6nfw2umHOwqsTqN5ZiNSW9XfuwPqo1VtSS/4 bPoi1HLX+orXiewBQlEEesGqgyfjD8RmUT+1ejcWElWQwhtr/CVZar8NiOYipJfdBnX+ z2rYjLQ+4YLc6mSdoO2EIPEAYLhcbXquYu9MZAMx4PO240Ks8aBTbCU4O8pQfuLfz6Tv doTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:organization :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=C074Ts6t1RuR/7tYyDWuvKC2BHBuBtLTBdnTVQAyV3k=; b=iOky04ZAfgKIpf0Kpcps50/ywACF193PP+tHJOkYa1SZhKE41Hn25C0U5iQ+6HRkJm 7yV0SaxxBsE5hbHHFqnYJX75lDDxOsSNbYlw1fRjT2tny2YTdWHcqsC9FO+dn1ANEDvm 5utWVZIdCVmVPjEAGNHcqcpGRhLVWlKx/4zyBpJprpk7Uv8sa5NuD4nOhzqbUSEtFHzA TptSajFlRjdPn+h478C7ilRo9wwAS0LADT7iYEE/2zAFf4Na3J6y+jrvcLcZxapWtIvK /6ceN9hdWnuk34LL56fBIjFiVHxBbb45GHOj5X3/1hDLNxrwidxiTuirtjjwv18r/9rA 1FMw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=BHfF3zx0; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s5si2666113edd.249.2022.02.09.07.03.57; Wed, 09 Feb 2022 07:04:26 -0800 (PST) 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=@gmail.com header.s=20210112 header.b=BHfF3zx0; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233851AbiBINGJ (ORCPT + 99 others); Wed, 9 Feb 2022 08:06:09 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43532 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233837AbiBINGH (ORCPT ); Wed, 9 Feb 2022 08:06:07 -0500 Received: from mail-lj1-x22a.google.com (mail-lj1-x22a.google.com [IPv6:2a00:1450:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3587FC05CBAB; Wed, 9 Feb 2022 05:06:10 -0800 (PST) Received: by mail-lj1-x22a.google.com with SMTP id bx31so3387669ljb.0; Wed, 09 Feb 2022 05:06:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:organization:content-transfer-encoding; bh=C074Ts6t1RuR/7tYyDWuvKC2BHBuBtLTBdnTVQAyV3k=; b=BHfF3zx0V2sP0D4d9+4rLjIs4WhIhNDY1dUvDT1BnjD0DoY60k4YLXk4vZ/2sX9o0l ic6L8cfdLiZwXPn5XfgUwasbajiL1E2a5wbpCgI6OGunSPXEFeCHRvsRaszS+yqW7zHl 0z42UAceKzRPgDE4Oo3DVcEfpJpyibXlIyVO3AdbvOSZz+EzcH8dX89ru+ljSjs23hEN Xzq7uvf29dXyR0yipFZ+NlhDZ63/YaepY2Hp5JhBWesdCFraQ4h0hKYQYZTb0NDIkPES R0KoHPC0Je6Y/1d9iaoX3c/w7ncJs99GNDZknH303itEaVbPUWhO+GfapMddu0S3bTCB +MRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:organization:content-transfer-encoding; bh=C074Ts6t1RuR/7tYyDWuvKC2BHBuBtLTBdnTVQAyV3k=; b=JnvyBALoMPT+8SNrxyha3j+FgqEyxVkf+RQtA/dyLIF1wURwA/eMbvEVvbPMo+NNCF u6+WvNajwlpQ53NC5z5HjofmN1h/QDeTlOU8+fyZz0ZxFt9//DDQYCvNOri/mBBKk23L 9uYrATPElXvjsUKxTQBmtW5EqyLKGThbND6KrZaM//kSVnQRiMtK1FjrTNk+UdowKwMG H/MXeDxWNljBCVcbaH3uzLLbzWLKuTTQHQpcDC3Gv0YKNTxbPCuN+hK7QTnksHVxkCtp URbWB+fOfL4u61i+2vKUF/yI8CNh9pt6WvPkWoFZ/Gjq5KvXuUZaAPdSsQkJ9yFAw5t9 Cw+Q== X-Gm-Message-State: AOAM531+5Lm+0x/aUHJwOu8lr82GWsYl+5srfb4JOpx5/mPRTF7m8LaR 9TnMcKDCwz9yWEgquM7oanQ= X-Received: by 2002:a2e:8081:: with SMTP id i1mr1513730ljg.506.1644411968590; Wed, 09 Feb 2022 05:06:08 -0800 (PST) Received: from wse-c0127.beijerelectronics.com ([208.127.141.29]) by smtp.gmail.com with ESMTPSA id k3sm2352608lfo.127.2022.02.09.05.06.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Feb 2022 05:06:08 -0800 (PST) From: Hans Schultz X-Google-Original-From: Hans Schultz To: davem@davemloft.net, kuba@kernel.org Cc: netdev@vger.kernel.org, Hans Schultz , Roopa Prabhu , Nikolay Aleksandrov , bridge@lists.linux-foundation.org, linux-kernel@vger.kernel.org Subject: [PATCH net-next v2 2/5] net: bridge: Add support for offloading of locked port flag Date: Wed, 9 Feb 2022 14:05:34 +0100 Message-Id: <20220209130538.533699-3-schultz.hans+netdev@gmail.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220209130538.533699-1-schultz.hans+netdev@gmail.com> References: <20220209130538.533699-1-schultz.hans+netdev@gmail.com> MIME-Version: 1.0 Organization: Westermo Network Technologies AB Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,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 Various switchcores support setting ports in locked mode, so that clients behind locked ports cannot send traffic through the port unless a fdb entry is added with the clients MAC address. Signed-off-by: Hans Schultz --- net/bridge/br_switchdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/bridge/br_switchdev.c b/net/bridge/br_switchdev.c index f8fbaaa7c501..bf549fc22556 100644 --- a/net/bridge/br_switchdev.c +++ b/net/bridge/br_switchdev.c @@ -72,7 +72,7 @@ bool nbp_switchdev_allowed_egress(const struct net_bridge_port *p, /* Flags that can be offloaded to hardware */ #define BR_PORT_FLAGS_HW_OFFLOAD (BR_LEARNING | BR_FLOOD | \ - BR_MCAST_FLOOD | BR_BCAST_FLOOD) + BR_MCAST_FLOOD | BR_BCAST_FLOOD | BR_PORT_LOCKED) int br_switchdev_set_port_flag(struct net_bridge_port *p, unsigned long flags, -- 2.30.2