On 2020/3/9 23:10, Leon Romanovsky wrote: >> static int set_extend_sge_param(struct hns_roce_dev *hr_dev, >> struct hns_roce_qp *hr_qp) >> { >> @@ -768,7 +744,10 @@ static void free_rq_inline_buf(struct hns_roce_qp *hr_qp) >> static int map_wqe_buf(struct hns_roce_dev *hr_dev, struct hns_roce_qp *hr_qp, >> u32 page_shift, bool is_user) >> { >> - dma_addr_t *buf_list[ARRAY_SIZE(hr_qp->regions)] = { NULL }; >> +/* WQE buffer include 3 parts: SQ, extend SGE and RQ. */ >> +#define HNS_ROCE_WQE_REGION_MAX 3 >> + struct hns_roce_buf_region regions[HNS_ROCE_WQE_REGION_MAX] = {}; >> + dma_addr_t *buf_list[HNS_ROCE_WQE_REGION_MAX] = { NULL }; > Nitpick, NULL is not needed. > > Thanks > OK, thank you. Weihang