RDMA/rxe: Remove references to ib_device and pool
authorBob Pearson <rpearsonhpe@gmail.com>
Mon, 25 Jan 2021 21:16:39 +0000 (15:16 -0600)
committerJason Gunthorpe <jgg@nvidia.com>
Thu, 28 Jan 2021 19:29:56 +0000 (15:29 -0400)
commit6cde3e8ec16f8318bab119ad1e16dd90677bc897
tree696fa8715ef2b91c1a09ea17dcb88d97b5e2aac0
parent4276fd0dddc98ee7d6c1a469b3f35b8ab51ddc2f
RDMA/rxe: Remove references to ib_device and pool

rxe_pool.c takes references to the pool and ib_device structs for each
object allocated and also keeps an atomic num_elem count in each
pool. This is more work than is needed. Pool allocation is only called
from verbs APIs which already have references to ib_device and pools are
only diasbled when the driver is removed so no protection of the pool
addresses are needed. The elem count is used to warn if elements are still
present in a pool when it is cleaned up which is useful.

This patch eliminates the references to the ib_device and pool structs.

Link: https://lore.kernel.org/r/20210125211641.2694-5-rpearson@hpe.com
Signed-off-by: Bob Pearson <rpearson@hpe.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/sw/rxe/rxe_pool.c
drivers/infiniband/sw/rxe/rxe_pool.h