Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp3715026pxp; Tue, 15 Mar 2022 05:01:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw/uaO8dqFnzs3u5nqo/rkRX1Q4ABy0FXTvXKfmFCyrSGwKbzF/vBRAecqlOYQxjSh41ig/ X-Received: by 2002:a17:906:3cea:b0:6da:ea45:ea9e with SMTP id d10-20020a1709063cea00b006daea45ea9emr22239449ejh.574.1647345690107; Tue, 15 Mar 2022 05:01:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1647345690; cv=none; d=google.com; s=arc-20160816; b=fRZC24KROKcbcPMMo6SaqW/mVUq945TvoQMPzR3Qc6CMY/fb2XMOrRdOjWR2mNcIsc eix8+FjMGSSAmdRrOrvdtiuN4ru3vCYLk3ooBnH2BCvC0iDQeeLuqsV3Z2K/e66FgcMP c3MB6mHAg//3qHLp5fX1ODbx4lldOKI1787z/LzgeA6ViZ9RAzC/4V9vC5PZua/g3yXT lOovsaR15vbInNvMWZ//OOthhiynPlhsB2uBRKldVmk3hJ83E0F31hO8lYM0OWR4ncRp qgd2V+vCfcFr09hR0AqwFmbx+vDIjx7DapwZKqDJnLMNN6AB57MJlO6Bo8Jv5iYfvM54 X9Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=NExbxl+i2kuO3Pvzdgbe/Iig/umuCg0Aqp3WMWOTSDA=; b=BbMP4JEL9TXktjsFdjgTjK36mR0IeTeNaysU88HtSq1tiKq6uSkZCIGBjNaHe2d/RG 9oAaVlFEaqUoUjcAde5ANK+JLe5Th6DtcacXnMW5nC3qx+FJzDRO/FNGVZAj5sKlPYDZ NBU93DUbp9nO4IQ1eRhvOJJGUn0/JjaPVmB+i5nqFV8gSrnMzXABmny4ufDuakOFKKdA oTN5jwpRV6q7ai6MO5J+gSjPNn9BixDA92B/DQYuYL30spQSx04zRhCYn0+wEVW1kRy/ 3O9is0Rs8Nenl/omfA36UIMZD7rRs/fVodIX0s4RBqBXlEpW9Qv8fCEY/rCW8X75K/fz 69jA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=bASI2gJC; 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 h18-20020a056402281200b004165aa5fcbcsi13564878ede.320.2022.03.15.05.01.04; Tue, 15 Mar 2022 05:01:30 -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; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=bASI2gJC; 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 S1347731AbiCOLBg (ORCPT + 99 others); Tue, 15 Mar 2022 07:01:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46136 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347734AbiCOLBd (ORCPT ); Tue, 15 Mar 2022 07:01:33 -0400 Received: from wout4-smtp.messagingengine.com (wout4-smtp.messagingengine.com [64.147.123.20]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 566953CFC5; Tue, 15 Mar 2022 04:00:22 -0700 (PDT) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.west.internal (Postfix) with ESMTP id D99753201F82; Tue, 15 Mar 2022 07:00:18 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Tue, 15 Mar 2022 07:00:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=NExbxl+i2kuO3Pvzdgbe/Iig/umuCg0Aqp3WMWOTS DA=; b=bASI2gJC467wslZAh/G66t63jB1zY0shNB3Wuma/AJ/qKyNks5ywiEv9L TjeFFh+XXl3Xba8pswlacUlwKsgv6XjO4tuUavk/8KW8tuiClxHPA2BzZajqfTYu I/uZjMvH74mB/42xUXfqjI554e/RudCwZgpyiDh8kDwbjypE18L2y6YKTQmqJzjL 7mTcc53No0wnYWnN+33WTsR38tuTr69ke7QiYaGaF7iFoR6rqY7RJTwLnaMFAzEU wbls6j+7Dt8oirYqY1Dbh6XhryFblkYZRiWcbtVCbeyEXYZsCO5bDI/c5Hr0/QTQ zcvbWWTTfSjlrGpd4XCbuUKtKKfRg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvvddrudeftddgvdduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvffukfhfgggtugfgjgesthekredttddtudenucfhrhhomhepkfguohcu ufgthhhimhhmvghluceoihguohhstghhsehiughoshgthhdrohhrgheqnecuggftrfgrth htvghrnhepvdffveekfeeiieeuieetudefkeevkeeuhfeuieduudetkeegleefvdegheej hefhnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepih guohhstghhsehiughoshgthhdrohhrgh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 15 Mar 2022 07:00:15 -0400 (EDT) Date: Tue, 15 Mar 2022 13:00:12 +0200 From: Ido Schimmel To: Hans Schultz Cc: davem@davemloft.net, kuba@kernel.org, netdev@vger.kernel.org, Andrew Lunn , Vivien Didelot , Florian Fainelli , Vladimir Oltean , Jiri Pirko , Ivan Vecera , Roopa Prabhu , Nikolay Aleksandrov , Daniel Borkmann , Ido Schimmel , linux-kernel@vger.kernel.org, bridge@lists.linux-foundation.org Subject: Re: [PATCH net-next 1/3] net: bridge: add fdb flag to extent locked port feature Message-ID: References: <20220310142320.611738-1-schultz.hans+netdev@gmail.com> <20220310142320.611738-2-schultz.hans+netdev@gmail.com> <86h77zha8b.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <86h77zha8b.fsf@gmail.com> X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL, SPF_HELO_PASS,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 Tue, Mar 15, 2022 at 09:48:52AM +0100, Hans Schultz wrote: > On m?n, mar 14, 2022 at 17:30, Ido Schimmel wrote: > > On Thu, Mar 10, 2022 at 03:23:18PM +0100, Hans Schultz wrote: > >> @@ -94,8 +95,16 @@ int br_handle_frame_finish(struct net *net, struct sock *sk, struct sk_buff *skb > >> br_fdb_find_rcu(br, eth_hdr(skb)->h_source, vid); > >> > >> if (!fdb_src || READ_ONCE(fdb_src->dst) != p || > >> - test_bit(BR_FDB_LOCAL, &fdb_src->flags)) > >> + test_bit(BR_FDB_LOCAL, &fdb_src->flags)) { > >> + if (!fdb_src) { > >> + set_bit(BR_FDB_ENTRY_LOCKED, &flags); > > > > This flag is read-only for user space, right? That is, the kernel needs > > to reject it during netlink policy validation. > > > > Yes, the flag is only readable from user space, unless there is a wish > to change that. OK, so please spell it out in the commit message so that it is clear the flag can only be set by the kernel.