]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/devices: Remove the lock around remove_client_context
authorJason Gunthorpe <jgg@mellanox.com>
Wed, 31 Jul 2019 08:18:41 +0000 (11:18 +0300)
committerDoug Ledford <dledford@redhat.com>
Thu, 1 Aug 2019 15:44:48 +0000 (11:44 -0400)
commit1a61aaf5ad5f5b401f080d9b7869098cca9c43fd
treecace05458bf51c0903ecaddede02f995f5df4261
parentc70caa6ed2f5c056e0906054ae594636474dedc7
RDMA/devices: Remove the lock around remove_client_context

Due to the complexity of client->remove() callbacks it is desirable to not
hold any locks while calling them. Remove the last one by tracking only
the highest client ID and running backwards from there over the xarray.

Since the only purpose of that lock was to protect the linked list, we can
drop the lock.

Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Link: https://lore.kernel.org/r/20190731081841.32345-3-leon@kernel.org
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/core/device.c
include/rdma/ib_verbs.h