net/mlx5e: IPoIB, Add ndo stats support for IPoIB child devices
authorFeras Daoud <ferasda@mellanox.com>
Sun, 2 Sep 2018 19:12:09 +0000 (22:12 +0300)
committerDavid S. Miller <davem@davemloft.net>
Sun, 2 Sep 2018 23:22:42 +0000 (16:22 -0700)
Expose RX and TX counters by implementing ndo_get_stats64 operation
for child devices.

Signed-off-by: Feras Daoud <ferasda@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Signed-off-by: Tariq Toukan <tariqt@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx5/core/ipoib/ipoib_vlan.c

index 54a188f41f90ca329f1f50e591a6e8fca85731fe..e3e8a5f1ac9b1daadc9970f22c5eb0dd0faea203 100644 (file)
@@ -146,6 +146,7 @@ static const struct net_device_ops mlx5i_pkey_netdev_ops = {
        .ndo_open                = mlx5i_pkey_open,
        .ndo_stop                = mlx5i_pkey_close,
        .ndo_init                = mlx5i_pkey_dev_init,
+       .ndo_get_stats64         = mlx5i_get_stats,
        .ndo_uninit              = mlx5i_pkey_dev_cleanup,
        .ndo_change_mtu          = mlx5i_pkey_change_mtu,
        .ndo_do_ioctl            = mlx5i_pkey_ioctl,