net/mlx5e: Remove redundant active_channels indication
[sfrench/cifs-2.6.git] / drivers / net / ethernet / mellanox / mlx5 / core / en_rep.c
index de6364125f0f369d08e7f283f41d8589570048cf..1fb4835eac72424a24163a3395e25ef7bc8a02c3 100644 (file)
@@ -130,10 +130,6 @@ static void mlx5e_rep_update_sw_counters(struct mlx5e_priv *priv)
        struct mlx5e_sq_stats *sq_stats;
        int i, j;
 
        struct mlx5e_sq_stats *sq_stats;
        int i, j;
 
-       read_lock(&priv->stats_lock);
-       if (!priv->channels_active)
-               goto out;
-
        memset(s, 0, sizeof(*s));
        for (i = 0; i < priv->channels.num; i++) {
                struct mlx5e_channel *c = priv->channels.c[i];
        memset(s, 0, sizeof(*s));
        for (i = 0; i < priv->channels.num; i++) {
                struct mlx5e_channel *c = priv->channels.c[i];
@@ -150,8 +146,6 @@ static void mlx5e_rep_update_sw_counters(struct mlx5e_priv *priv)
                        s->tx_bytes             += sq_stats->bytes;
                }
        }
                        s->tx_bytes             += sq_stats->bytes;
                }
        }
-out:
-       read_unlock(&priv->stats_lock);
 }
 
 static void mlx5e_rep_get_ethtool_stats(struct net_device *dev,
 }
 
 static void mlx5e_rep_get_ethtool_stats(struct net_device *dev,