[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20160419.184920.1193931883675948435.davem@davemloft.net>
Date: Tue, 19 Apr 2016 18:49:20 -0400 (EDT)
From: David Miller <davem@...emloft.net>
To: roopa@...ulusnetworks.com
Cc: eric.dumazet@...il.com, netdev@...r.kernel.org, jhs@...atatu.com,
tgraf@...g.ch, nicolas.dichtel@...nd.com
Subject: Re: [PATCH net-next v5] rtnetlink: add new RTM_GETSTATS message to
dump link stats
From: Roopa Prabhu <roopa@...ulusnetworks.com>
Date: Tue, 19 Apr 2016 12:05:00 -0700
> ok, will do. one thing though, for GETSTATS, if I need a pad
> attribute like IFLA_PAD, I will need to add a new stats attribute
> IFLA_STATS_PAD and burn a bit for it in filter_mask too. In which
> case, I am wondering if we should live with the copy. I will take
> any suggestions here.
I don't think the copy is appropriate, especially if the existing full
link state dump gets away without it. We're adding this facility for
performance reasons after all.
You have several options to avoid wasting filter mask space. For
example, you could use IFLA_STATS_UNSPEC, which should be OK since
only new applications will use these.
Or you could make IFLA_STATS_PAD the first attribute, and define the
filter mask as relative to it. Ie. IFLA_STATS_LINK_64 uses bit
(IFLA_STATS_LINK_64 - IFLA_STATS_PAD), etc.
Powered by blists - more mailing lists