Return-Path: Date: Wed, 11 Dec 2019 12:01:20 -0800 (PST) Message-Id: <20191211.120120.991784482938734303.davem@davemloft.net> From: David Miller In-Reply-To: <20191211134133.GB1587652@t480s.localdomain> References: <0e45fd22-c31b-a9c2-bf87-22c16a60aeb4@gmail.com> <9f978ee1-08ee-aa57-6e3d-9b68657eeb14@cumulusnetworks.com> <20191211134133.GB1587652@t480s.localdomain> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: Re: [Bridge] [PATCH net-next v2] net: bridge: add STP xstats List-Id: Linux Ethernet Bridging List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: vivien.didelot@gmail.com Cc: nikolay@cumulusnetworks.com, netdev@vger.kernel.org, roopa@cumulusnetworks.com, bridge@lists.linux-foundation.org, dsahern@gmail.com From: Vivien Didelot Date: Wed, 11 Dec 2019 13:41:33 -0500 > Hi David, Nikolay, > > On Wed, 11 Dec 2019 17:42:33 +0200, Nikolay Aleksandrov wrote: >> >> /* Bridge multicast database attributes >> >> * [MDBA_MDB] = { >> >> * [MDBA_MDB_ENTRY] = { >> >> @@ -261,6 +270,7 @@ enum { >> >> BRIDGE_XSTATS_UNSPEC, >> >> BRIDGE_XSTATS_VLAN, >> >> BRIDGE_XSTATS_MCAST, >> >> + BRIDGE_XSTATS_STP, >> >> BRIDGE_XSTATS_PAD, >> >> __BRIDGE_XSTATS_MAX >> >> }; >> > >> > Shouldn't the new entry be appended to the end - after BRIDGE_XSTATS_PAD >> > >> >> Oh yes, good catch. That has to be fixed, too. >> > > This I don't get. Why new attributes must come between BRIDGE_XSTATS_PAD > and __BRIDGE_XSTATS_MAX? Because, just like any other attribute value, BRIDGE_XSTATS_PAD is an API and fixed in stone. You can't add things before it which change it's value.