summaryrefslogtreecommitdiff
path: root/drivers/net/mlx5/mlx5_mr.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_mr.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_mr.c')
-rw-r--r--drivers/net/mlx5/mlx5_mr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/mlx5/mlx5_mr.c b/drivers/net/mlx5/mlx5_mr.c
index 6624d0f..3b7b6d1 100644
--- a/drivers/net/mlx5/mlx5_mr.c
+++ b/drivers/net/mlx5/mlx5_mr.c
@@ -164,9 +164,9 @@ mlx5_txq_mp2mr_reg(struct mlx5_txq_data *txq, struct rte_mempool *mp,
container_of(txq, struct mlx5_txq_ctrl, txq);
struct mlx5_mr *mr;
- priv_lock(txq_ctrl->priv);
+ rte_spinlock_lock(&txq_ctrl->priv->mr_lock);
mr = priv_txq_mp2mr_reg(txq_ctrl->priv, txq, mp, idx);
- priv_unlock(txq_ctrl->priv);
+ rte_spinlock_unlock(&txq_ctrl->priv->mr_lock);
return mr;
}