mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
net: make ndo_get_stats64 a void function
The network device operation for reading statistics is only called in one place, and it ignores the return value. Having a structure return value is potentially confusing because some future driver could incorrectly assume that the return value was used. Fix all drivers with ndo_get_stats64 to have a void function. Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
63c64de7be
commit
bc1f44709c
82 changed files with 166 additions and 309 deletions
|
@ -97,8 +97,8 @@ static netdev_tx_t loopback_xmit(struct sk_buff *skb,
|
|||
return NETDEV_TX_OK;
|
||||
}
|
||||
|
||||
static struct rtnl_link_stats64 *loopback_get_stats64(struct net_device *dev,
|
||||
struct rtnl_link_stats64 *stats)
|
||||
static void loopback_get_stats64(struct net_device *dev,
|
||||
struct rtnl_link_stats64 *stats)
|
||||
{
|
||||
u64 bytes = 0;
|
||||
u64 packets = 0;
|
||||
|
@ -122,7 +122,6 @@ static struct rtnl_link_stats64 *loopback_get_stats64(struct net_device *dev,
|
|||
stats->tx_packets = packets;
|
||||
stats->rx_bytes = bytes;
|
||||
stats->tx_bytes = bytes;
|
||||
return stats;
|
||||
}
|
||||
|
||||
static u32 always_on(struct net_device *dev)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue