lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <56E7AD8C.5000701@cumulusnetworks.com>
Date:	Mon, 14 Mar 2016 23:37:00 -0700
From:	roopa <roopa@...ulusnetworks.com>
To:	Elad Raz <eladr@...lanox.com>
CC:	"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
	"jhs@...atatu.com" <jhs@...atatu.com>,
	"davem@...emloft.net" <davem@...emloft.net>,
	Jiri Pirko <jiri@...lanox.com>,
	Ido Schimmel <idosch@...lanox.com>
Subject: Re: [PATCH net-next 1/2] rtnetlink: add new RTM_GETSTATS message
 to dump link stats

On 3/14/16, 8:11 AM, Elad Raz wrote:
>
>> -----Original Message-----
>> From: netdev-owner@...r.kernel.org [mailto:netdev-owner@...r.kernel.org]
>> On Behalf Of Roopa Prabhu
>> Sent: Sunday, March 13, 2016 3:56 AM
>> To: netdev@...r.kernel.org
>> Cc: jhs@...atatu.com; davem@...emloft.net
>> Subject: [PATCH net-next 1/2] rtnetlink: add new RTM_GETSTATS message to
>> dump link stats
>>
>> From: Roopa Prabhu <roopa@...ulusnetworks.com>
>>
[snip]
>> Future possible new types of stat attributes:
>> - IFLA_MPLS_STATS  (nested. for mpls/mdev stats)
>> - IFLA_EXTENDED_STATS (nested. extended software netdev stats like
>> bridge,
>>   vlan, vxlan etc)
>> - IFLA_EXTENDED_HW_STATS (nested. extended hardware stats which are
>>   available via ethtool today)
>>
>> This patch also declares a filter mask for all stat attributes.
>> User has to provide a mask of stats attributes to query. This will be
>> specified in a new hdr 'struct if_stats_msg' for stats messages.
>>
>> Without any attributes in the filter_mask, no stats will be returned.
>>
>> This patch has been tested with modified iproute2 ifstat.
>>
>> Suggested-by: Jamal Hadi Salim <jhs@...atatu.com>
>> Signed-off-by: Roopa Prabhu <roopa@...ulusnetworks.com>
>> ---
>>  
[snip]
>> diff --git a/include/uapi/linux/rtnetlink.h
>> b/include/uapi/linux/rtnetlink.h index ca764b5..2bbb300 100644
>> --- a/include/uapi/linux/rtnetlink.h
>> +++ b/include/uapi/linux/rtnetlink.h
>> @@ -139,6 +139,13 @@ enum {
>>  	RTM_GETNSID = 90,
>>  #define RTM_GETNSID RTM_GETNSID
>>
>> +	RTM_NEWSTATS = 92,
>> +#define RTM_NEWSTATS RTM_NEWSTATS
> I think that RTM_NEWSTATS and RTM_DELSTATS aren't good names, since user doesn't add/del statistics but only query.
> Maybe just stay with RTM_GETSTATS and the message back to user will be RTM_GETSTATS as well?

yeah, i defined all of these because rtnetlink_rcv_msg seems to expect all three to be
there when it tries to check if it is a get msg. But, i could sure not declare this
but make rtnetlink_rcv_msg happy by keeping the GET msg at the right offset.

The RTM_NEWSTATS i thought i should leave it in there because the original thought from
jamal also had periodic stats notification to user-space...which should be RTM_NEWSTATS.
 But, then again that can be added  when we implement that function.


>
>> +	RTM_DELSTATS = 93,
>> +#define RTM_DELSTATS RTM_DELSTATS
> This is not in used
>
>
same response as above. will drop some of them in v2.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ