summaryrefslogtreecommitdiff
path: root/drivers/net/mlx5/mlx5_rss.c
diff options
context:
space:
mode:
authorNĂ©lio Laranjeiro <nelio.laranjeiro@6wind.com>2018-03-05 13:21:03 +0100
committerFerruh Yigit <ferruh.yigit@intel.com>2018-03-30 14:08:44 +0200
commit7b2423cd2e84c61d3052147cea7643d15d49d1e9 (patch)
tree1de0d7cd98166f5577ea08352c7c85c07aa2a962 /drivers/net/mlx5/mlx5_rss.c
parent0b3456e391a6518e26c60ab2aa6546964d46a6f6 (diff)
downloaddpdk-next-eventdev-7b2423cd2e84c61d3052147cea7643d15d49d1e9.zip
dpdk-next-eventdev-7b2423cd2e84c61d3052147cea7643d15d49d1e9.tar.gz
dpdk-next-eventdev-7b2423cd2e84c61d3052147cea7643d15d49d1e9.tar.xz
net/mlx5: remove control path locks
In priv struct only the memory region needs to be protected against concurrent access between the control plane and the data plane. Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com> Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Diffstat (limited to 'drivers/net/mlx5/mlx5_rss.c')
-rw-r--r--drivers/net/mlx5/mlx5_rss.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/drivers/net/mlx5/mlx5_rss.c b/drivers/net/mlx5/mlx5_rss.c
index 8f5c8be..4b88215 100644
--- a/drivers/net/mlx5/mlx5_rss.c
+++ b/drivers/net/mlx5/mlx5_rss.c
@@ -44,7 +44,6 @@ mlx5_rss_hash_update(struct rte_eth_dev *dev,
struct priv *priv = dev->data->dev_private;
int ret = 0;
- priv_lock(priv);
if (rss_conf->rss_hf & MLX5_RSS_HF_MASK) {
ret = -EINVAL;
goto out;
@@ -62,7 +61,6 @@ mlx5_rss_hash_update(struct rte_eth_dev *dev,
}
priv->rss_conf.rss_hf = rss_conf->rss_hf;
out:
- priv_unlock(priv);
return ret;
}
@@ -85,7 +83,6 @@ mlx5_rss_hash_conf_get(struct rte_eth_dev *dev,
if (!rss_conf)
return -EINVAL;
- priv_lock(priv);
if (rss_conf->rss_key &&
(rss_conf->rss_key_len >= priv->rss_conf.rss_key_len)) {
memcpy(rss_conf->rss_key, priv->rss_conf.rss_key,
@@ -93,7 +90,6 @@ mlx5_rss_hash_conf_get(struct rte_eth_dev *dev,
}
rss_conf->rss_key_len = priv->rss_conf.rss_key_len;
rss_conf->rss_hf = priv->rss_conf.rss_hf;
- priv_unlock(priv);
return 0;
}
@@ -222,9 +218,7 @@ mlx5_dev_rss_reta_query(struct rte_eth_dev *dev,
int ret;
struct priv *priv = dev->data->dev_private;
- priv_lock(priv);
ret = priv_dev_rss_reta_query(priv, reta_conf, reta_size);
- priv_unlock(priv);
return -ret;
}
@@ -249,9 +243,7 @@ mlx5_dev_rss_reta_update(struct rte_eth_dev *dev,
int ret;
struct priv *priv = dev->data->dev_private;
- priv_lock(priv);
ret = priv_dev_rss_reta_update(priv, reta_conf, reta_size);
- priv_unlock(priv);
if (dev->data->dev_started) {
mlx5_dev_stop(dev);
mlx5_dev_start(dev);