]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
net/mlx5: hw counters: Remove mlx5_fc_create_ex
authorCosmin Ratiu <cratiu@nvidia.com>
Tue, 1 Oct 2024 10:37:09 +0000 (13:37 +0300)
committerJakub Kicinski <kuba@kernel.org>
Fri, 4 Oct 2024 18:33:47 +0000 (11:33 -0700)
It no longer serves any purpose and is identical to mlx5_fc_create upon
which it was originally based of.

Signed-off-by: Cosmin Ratiu <cratiu@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Link: https://patch.msgid.link/20241001103709.58127-7-tariqt@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/en/tc_ct.c
drivers/net/ethernet/mellanox/mlx5/core/fs_counters.c
include/linux/mlx5/fs.h

index dcfccaaa8d917b670380621c20c03b546e9a885c..4877a9d86807ac3d2dc789a017291b6dae3d5348 100644 (file)
@@ -1026,7 +1026,7 @@ mlx5_tc_ct_counter_create(struct mlx5_tc_ct_priv *ct_priv)
                return ERR_PTR(-ENOMEM);
 
        counter->is_shared = false;
-       counter->counter = mlx5_fc_create_ex(ct_priv->dev, true);
+       counter->counter = mlx5_fc_create(ct_priv->dev, true);
        if (IS_ERR(counter->counter)) {
                ct_dbg("Failed to create counter for ct entry");
                ret = PTR_ERR(counter->counter);
index 0b80c33cba5fd3e2113b05ba32c2d30353b4caa0..62d0c689796b975f30de710249bddc4985efde24 100644 (file)
@@ -275,7 +275,7 @@ static struct mlx5_fc *mlx5_fc_acquire(struct mlx5_core_dev *dev, bool aging)
        return mlx5_fc_single_alloc(dev);
 }
 
-struct mlx5_fc *mlx5_fc_create_ex(struct mlx5_core_dev *dev, bool aging)
+struct mlx5_fc *mlx5_fc_create(struct mlx5_core_dev *dev, bool aging)
 {
        struct mlx5_fc *counter = mlx5_fc_acquire(dev, aging);
        struct mlx5_fc_stats *fc_stats = dev->priv.fc_stats;
@@ -304,11 +304,6 @@ err_out_alloc:
        mlx5_fc_release(dev, counter);
        return ERR_PTR(err);
 }
-
-struct mlx5_fc *mlx5_fc_create(struct mlx5_core_dev *dev, bool aging)
-{
-       return mlx5_fc_create_ex(dev, aging);
-}
 EXPORT_SYMBOL(mlx5_fc_create);
 
 u32 mlx5_fc_id(struct mlx5_fc *counter)
index b744e554f014d1a7bd64a0b61a1df40871c0f422..438db888bde0d6b0467ed0a7c2296badbc490bcf 100644 (file)
@@ -298,9 +298,6 @@ int mlx5_modify_rule_destination(struct mlx5_flow_handle *handler,
 
 struct mlx5_fc *mlx5_fc_create(struct mlx5_core_dev *dev, bool aging);
 
-/* As mlx5_fc_create() but doesn't queue stats refresh thread. */
-struct mlx5_fc *mlx5_fc_create_ex(struct mlx5_core_dev *dev, bool aging);
-
 void mlx5_fc_destroy(struct mlx5_core_dev *dev, struct mlx5_fc *counter);
 u64 mlx5_fc_query_lastuse(struct mlx5_fc *counter);
 void mlx5_fc_query_cached(struct mlx5_fc *counter,