From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.5 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,MAILING_LIST_MULTI, NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2F3CDC433E6 for ; Thu, 11 Feb 2021 04:21:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D932C60C40 for ; Thu, 11 Feb 2021 04:21:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229849AbhBKEVZ (ORCPT ); Wed, 10 Feb 2021 23:21:25 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51292 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229699AbhBKEVG (ORCPT ); Wed, 10 Feb 2021 23:21:06 -0500 Received: from mail-pl1-x635.google.com (mail-pl1-x635.google.com [IPv6:2607:f8b0:4864:20::635]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 30E75C061574; Wed, 10 Feb 2021 20:20:26 -0800 (PST) Received: by mail-pl1-x635.google.com with SMTP id d13so2645050plg.0; Wed, 10 Feb 2021 20:20:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=ofWIvbul8lUQjDjEqyhG2qv/DpTdeTq9suCAukT4VnE=; b=cJkf+VIciLaXv1lixjdR8iXxDvJD4ZVrqUo9pLZZOczna0nt6lXw+gvOZNbOiFr9Ax xXLtvTJtKB5ICTmJeynxBdn39We/Qj+tzybWJLI+YpQpya8NbF7CEqhU7uDvPD9/+aOb X0MP9xdLMPmQZ1cdXlY2M8wEiztJgbsc+o3R1enU36K44psdbuPcp0FECGfnmjGLvkEl pbmJ/ca9FeGs5zLyGfHWDyiQ2R41jRN6favzNvY7kfjbXs7nx57QxGt5Mgrp1a/IBocm NkcfcU38GSec03drey6h7xPphlkEwIMZIn88AfGtDhxqRP3qliCqabex9N/PNUJs9bvl 9l8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=ofWIvbul8lUQjDjEqyhG2qv/DpTdeTq9suCAukT4VnE=; b=LK7MAF56gcTYHmG9U9VDdUJMKYlNzcxhecNFu5Nau7DdctBPY0+fJWs8+UUKeT+rb2 8626HbSRRtv3N9iCCI91t9DNYNEFoj4dTMc/wE5f3G+6BYGMk0dY9OxmNgjliCNbPiib gjFNWdgj/3PMkDtK5FrkRP9KAq//6H+zuU2M3n0V2th2yPMnmHONuXcDTWjKjM4m/FEP 9JNyRjQbiv7WvcWR2sBvJ7VeZ9f/z2vlsfn7WIdk1dAdXRLNMd/uK9Jgdp7lEc44W+7l emDhvJbUj7CI5kkzez92/chx7Evwb+B59R4O/PjFtpN4b+tOX+AG0YpCWYi8LbFHOEJc QdGg== X-Gm-Message-State: AOAM530w/szf/FU96G24tdTjbNd2+rKXZ/VAuih91bxSO+MF4eDgWZpI MWd/WyU1RAPyBWcB7+w7pzySRQ3rfWM= X-Google-Smtp-Source: ABdhPJxywamPXOiUFuBiMJGeS5MBf6KcEI2wQhgt6ksWCRY9UWhZ7BoITqmymMwz37b/iZ4sU43/7g== X-Received: by 2002:a17:902:7847:b029:df:d889:252c with SMTP id e7-20020a1709027847b02900dfd889252cmr5985974pln.76.1613017225380; Wed, 10 Feb 2021 20:20:25 -0800 (PST) Received: from [10.230.29.30] ([192.19.223.252]) by smtp.gmail.com with ESMTPSA id 68sm3644935pfe.33.2021.02.10.20.20.22 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 10 Feb 2021 20:20:24 -0800 (PST) Subject: Re: [PATCH v3 net-next 10/11] net: mscc: ocelot: offload bridge port flags to device To: Vladimir Oltean , Jakub Kicinski , "David S. Miller" Cc: Andrew Lunn , Vivien Didelot , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, bridge@lists.linux-foundation.org, Roopa Prabhu , Nikolay Aleksandrov , Jiri Pirko , Ido Schimmel , Claudiu Manoil , Alexandre Belloni , UNGLinuxDriver@microchip.com, Vadym Kochan , Taras Chornyi , Grygorii Strashko , Ioana Ciornei , Ivan Vecera , linux-omap@vger.kernel.org References: <20210210091445.741269-1-olteanv@gmail.com> <20210210091445.741269-11-olteanv@gmail.com> From: Florian Fainelli Message-ID: Date: Wed, 10 Feb 2021 20:20:21 -0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0 Thunderbird/78.7.1 MIME-Version: 1.0 In-Reply-To: <20210210091445.741269-11-olteanv@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On 2/10/2021 1:14 AM, Vladimir Oltean wrote: > From: Vladimir Oltean > > We should not be unconditionally enabling address learning, since doing > that is actively detrimential when a port is standalone and not offloading > a bridge. Namely, if a port in the switch is standalone and others are > offloading the bridge, then we could enter a situation where we learn an > address towards the standalone port, but the bridged ports could not > forward the packet there, because the CPU is the only path between the > standalone and the bridged ports. The solution of course is to not > enable address learning unless the bridge asks for it. > > We need to set up the initial port flags for no learning and flooding > everything, then the bridge takes over. The flood configuration was > already configured ok in ocelot_init, we just need to disable learning > in ocelot_init_port. > > Signed-off-by: Vladimir Oltean > Reviewed-by: Alexandre Belloni Reviewed-by: Florian Fainelli -- Florian