lkml.org 
[lkml]   [2017]   [Feb]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v3 net-next 4/9] sunvnet: add driver stats for ethtool support
From
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 10 Feb 2017 16:22:08 -0800

> On Fri, 10 Feb 2017 09:38:20 -0800
> Shannon Nelson <shannon.nelson@oracle.com> wrote:
>
>> +static void vsw_get_ethtool_stats(struct net_device *dev,
>> + struct ethtool_stats *estats, u64 *data)
>> +{
>> + int i = 0;
>> +
>> + data[i++] = dev->stats.rx_packets;
>> + data[i++] = dev->stats.tx_packets;
>> + data[i++] = dev->stats.rx_bytes;
>> + data[i++] = dev->stats.tx_bytes;
>> + data[i++] = dev->stats.rx_errors;
>> + data[i++] = dev->stats.tx_errors;
>> + data[i++] = dev->stats.rx_dropped;
>> + data[i++] = dev->stats.tx_dropped;
>> + data[i++] = dev->stats.multicast;
>
> Please do not duplicate regular network statistics into ethtool.
> This doesn't really add any value.

Agreed.

\
 
 \ /
  Last update: 2017-02-12 03:01    [W:0.052 / U:0.196 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site