This series optimizes multi-level addressing for hns. Patch #1, #2 and #6 are optimization of multi-level addressing codes. Patch #3 is prepared for the following optimizations. Patch #4 and #5 introduce adaptive pagesize and hopnum to improve HW performance. v1 -> v2: * Remove the kmem page size modification in patch #4. Only adjust page size for umem. Chengchang Tang (5): RDMA/hns: Refactor mtr find RDMA/hns: Refactor mtr_init_buf_cfg() RDMA/hns: Alloc MTR memory before alloc_mtt() RDMA/hns: Support flexible umem page size RDMA/hns: Support adaptive PBL hopnum Yunsheng Lin (1): RDMA/hns: Simplify 'struct hns_roce_hem' allocation drivers/infiniband/hw/hns/hns_roce_cq.c | 11 +- drivers/infiniband/hw/hns/hns_roce_device.h | 16 +- drivers/infiniband/hw/hns/hns_roce_hem.c | 95 ++---- drivers/infiniband/hw/hns/hns_roce_hem.h | 56 +--- drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 111 ++++--- drivers/infiniband/hw/hns/hns_roce_mr.c | 339 ++++++++++++++------ 6 files changed, 339 insertions(+), 289 deletions(-) -- 2.30.0