From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752211AbcGSE0I (ORCPT ); Tue, 19 Jul 2016 00:26:08 -0400 Received: from mail-oi0-f42.google.com ([209.85.218.42]:35511 "EHLO mail-oi0-f42.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750769AbcGSE0E (ORCPT ); Tue, 19 Jul 2016 00:26:04 -0400 Subject: Re: [PATCH net-next v3 10/12] net: dsa: support switchdev ageing time attr To: Andrew Lunn , Vivien Didelot References: <20160719004540.1066-1-vivien.didelot@savoirfairelinux.com> <20160719004540.1066-11-vivien.didelot@savoirfairelinux.com> <20160719032415.GD9111@lunn.ch> Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com, "David S. Miller" From: Florian Fainelli Message-ID: Date: Mon, 18 Jul 2016 21:26:00 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <20160719032415.GD9111@lunn.ch> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Le 18/07/2016 à 20:24, Andrew Lunn a écrit : > On Mon, Jul 18, 2016 at 08:45:38PM -0400, Vivien Didelot wrote: >> Add a new function for DSA drivers to handle the switchdev >> SWITCHDEV_ATTR_ID_BRIDGE_AGEING_TIME attribute. >> >> The ageing time is passed as milliseconds. >> >> Also because we can have multiple logical bridges on top of a physical >> switch and ageing time are switch-wide, call the driver function with >> the fastest ageing time in use on the chip instead of the requested one. >> >> Signed-off-by: Vivien Didelot >> --- >> include/net/dsa.h | 2 ++ >> net/dsa/slave.c | 41 +++++++++++++++++++++++++++++++++++++++++ > Hi Andrew, > Hi Florian > > It looks like the SF2 can do fast ageing per port. What i don't see if > what configuration options you have. Can you get the fast and the > normal age time per port? Or is it global? The normal ageing is global and the value needs to be programmed in seconds, can can range from 10 to 1,048,575 (encoded on 20 bits). The fast-ageing can actually be per-port, per-VLAN id, for just dynamic or static entries etc. and is just a poor name for a flush based on any of these criteria. -- Florian