Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752185AbdFGTj6 (ORCPT ); Wed, 7 Jun 2017 15:39:58 -0400 Received: from mail-wm0-f68.google.com ([74.125.82.68]:36443 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751704AbdFGTj5 (ORCPT ); Wed, 7 Jun 2017 15:39:57 -0400 Subject: Re: [PATCH net-next 2/5] net: dsa: check VLAN capability of every switch To: Vivien Didelot , netdev@vger.kernel.org Cc: linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com, "David S. Miller" , Andrew Lunn References: <20170606205631.22880-1-vivien.didelot@savoirfairelinux.com> <20170606205631.22880-3-vivien.didelot@savoirfairelinux.com> From: Florian Fainelli Message-ID: <8d6edbe3-a80b-6cc7-b7ec-d8f1578dea27@gmail.com> Date: Wed, 7 Jun 2017 12:39:51 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: <20170606205631.22880-3-vivien.didelot@savoirfairelinux.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 959 Lines: 23 On 06/06/2017 01:56 PM, Vivien Didelot wrote: > Now that the VLAN object is propagated to every switch chip of the > switch fabric, we can easily ensure that they all support the required > VLAN operations before modifying an entry on a single switch. > > To achieve that, remove the condition skipping other target switches, > and add a bitmap of VLAN members, eventually containing the target port, > if we are programming the switch target. You could add in the commit message that with this commit, there is not actually a functional change yet because we have one (and only one) bit set in the members bitmap. > > This will allow us to easily add other VLAN members, such as the DSA or > CPU ports (to introduce cross-chip VLAN support) or the other port > members if we want to reduce hardware accesses later. > > Signed-off-by: Vivien Didelot Reviewed-by: Florian Fainelli -- Florian