RDMA/rxe: Save object pointer in pool element
authorBob Pearson <rpearsonhpe@gmail.com>
Wed, 3 Nov 2021 05:02:33 +0000 (00:02 -0500)
committerJason Gunthorpe <jgg@nvidia.com>
Fri, 19 Nov 2021 17:29:15 +0000 (13:29 -0400)
commitb92d766c87022fc82cd6da774010b71ee92fc3d3
tree419f6e563aab0a658d09e683a7a124fb3dbe07fa
parentc95acedbff6757499fcd4a55b6776c1685d12801
RDMA/rxe: Save object pointer in pool element

In rxe_pool.c currently there are many cases where it is necessary to
compute the offset from a pool element struct to the object containing it
in a type independent way where the offset is different for each type.  By
saving a pointer to the object when they are created extra work can be
saved.

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