aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/mlx5/mlx5_ib.h
diff options
context:
space:
mode:
authorAharon Landau <aharonl@nvidia.com>2022-07-26 10:19:07 +0300
committerJason Gunthorpe <jgg@nvidia.com>2022-07-27 14:45:48 -0300
commit17ae355926ed1832449d52748334b8fa799301f1 (patch)
tree44abd1fe91c3e08686b41d5be950720b3ea69e6c /drivers/infiniband/hw/mlx5/mlx5_ib.h
parentRevert "RDMA/rxe: Create duplicate mapping tables for FMRs" (diff)
downloadlinux-dev-17ae355926ed1832449d52748334b8fa799301f1.tar.xz
linux-dev-17ae355926ed1832449d52748334b8fa799301f1.zip
RDMA/mlx5: Replace ent->lock with xa_lock
In the next patch, ent->list will be replaced with an xarray. The xarray uses an internal lock to protect the indexes. Use it to protect all the entry fields, and get rid of ent->lock. Link: https://lore.kernel.org/r/20220726071911.122765-2-michaelgur@nvidia.com Signed-off-by: Aharon Landau <aharonl@nvidia.com> Signed-off-by: Leon Romanovsky <leonro@nvidia.com> Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'drivers/infiniband/hw/mlx5/mlx5_ib.h')
-rw-r--r--drivers/infiniband/hw/mlx5/mlx5_ib.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/infiniband/hw/mlx5/mlx5_ib.h b/drivers/infiniband/hw/mlx5/mlx5_ib.h
index 688ee7c05a8f..42bc58967b1f 100644
--- a/drivers/infiniband/hw/mlx5/mlx5_ib.h
+++ b/drivers/infiniband/hw/mlx5/mlx5_ib.h
@@ -743,11 +743,8 @@ struct umr_common {
};
struct mlx5_cache_ent {
+ struct xarray mkeys;
struct list_head head;
- /* sync access to the cahce entry
- */
- spinlock_t lock;
-
char name[4];
u32 order;