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. 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 pagesize RDMA/hns: Support adaptive PBL hopnum Yunsheng Lin (1): RDMA/hns: Simplify 'struct hns_roce_hem' allocation drivers/infiniband/hw/hns/hns_roce_alloc.c | 6 - 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 | 386 +++++++++++++++----- 7 files changed, 386 insertions(+), 295 deletions(-) -- 2.30.0