RDMA/ucma: Remove mc_list and rely on xarray
authorJason Gunthorpe <jgg@nvidia.com>
Tue, 18 Aug 2020 12:05:17 +0000 (15:05 +0300)
committerJason Gunthorpe <jgg@nvidia.com>
Thu, 27 Aug 2020 11:38:14 +0000 (08:38 -0300)
commit95fe51096b7adf1d1e7315c49c75e2f75f162584
tree3264ea953dcfe623c712183e90ebee412ffc55dc
parent620db1a1183d69cc49981ee59c9207e53befeae4
RDMA/ucma: Remove mc_list and rely on xarray

It is not really necessary to keep a linked list of mcs associated with
each context when we can just scan the xarray to find the right things.

The removes another overloading of file->mut by relying on the xarray
locking for mc instead.

Link: https://lore.kernel.org/r/20200818120526.702120-6-leon@kernel.org
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/core/ucma.c