RDMA/rxe: Cleanup page variables in rxe_mr.c
authorBob Pearson <rpearsonhpe@gmail.com>
Thu, 19 Jan 2023 23:59:36 +0000 (17:59 -0600)
committerJason Gunthorpe <jgg@nvidia.com>
Thu, 26 Jan 2023 19:04:46 +0000 (15:04 -0400)
commit325a7eb85199ec9c5b5a7af812f43ea16b735569
tree29c36daa0255d148665e4081afee8af4dc573110
parentd8bdb0ebca086b5845d782e800ad2bf2a7eb4877
RDMA/rxe: Cleanup page variables in rxe_mr.c

Cleanup usage of mr->page_shift and mr->page_mask and introduce
an extractor for mr->ibmr.page_size. Normal usage in the kernel
has page_mask masking out offset in page rather than masking out
the page number. The rxe driver had reversed that which was confusing.
Implicitly there can be a per mr page_size which was not uniformly
supported.

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