]> git.baikalelectronics.ru Git - kernel.git/commit
IB/uverbs: Clarify and revise uverbs_close_fd
authorJason Gunthorpe <jgg@mellanox.com>
Wed, 11 Jul 2018 02:55:17 +0000 (20:55 -0600)
committerJason Gunthorpe <jgg@mellanox.com>
Wed, 25 Jul 2018 20:21:22 +0000 (14:21 -0600)
commitf65c62d2d273f19e74c0122ef5383fc4f02521d6
tree4939b1a725ed92bc42c23726fbc130b097013e4b
parent87d5d962846d83a11188e3d9bffdc2ee4340fc23
IB/uverbs: Clarify and revise uverbs_close_fd

The locking requirements here have changed slightly now that we can rely
on the ib_uverbs_file always existing and containing all the necessary
locking infrastructure.

That means we can get rid of the cleanup_mutex usage (this was protecting
the check on !uboj->context).

Otherwise, follow the same pattern that IDR uses for destroy, acquire
exclusive write access, then call destroy and the undo the 'lookup'.

Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/core/rdma_core.c