On Wed, May 12, 2021 at 04:16:10PM +0800, Weihang Li wrote: > From: Xi Wang <wangxi11@xxxxxxxxxx> > > The timeout link table works in HIP08 ES version and the hns driver only > support the CS version for HIP08, so delete the related code. > > Signed-off-by: Xi Wang <wangxi11@xxxxxxxxxx> > Signed-off-by: Weihang Li <liweihang@xxxxxxxxxx> > --- > drivers/infiniband/hw/hns/hns_roce_device.h | 3 +- > drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 177 +++++++++++----------------- > drivers/infiniband/hw/hns/hns_roce_hw_v2.h | 16 +-- > 3 files changed, 76 insertions(+), 120 deletions(-) > > diff --git a/drivers/infiniband/hw/hns/hns_roce_device.h b/drivers/infiniband/hw/hns/hns_roce_device.h > index 97800d2..5bd4013 100644 > --- a/drivers/infiniband/hw/hns/hns_roce_device.h > +++ b/drivers/infiniband/hw/hns/hns_roce_device.h > @@ -854,8 +854,7 @@ struct hns_roce_caps { > u32 gmv_buf_pg_sz; > u32 gmv_hop_num; > u32 sl_num; > - u32 tsq_buf_pg_sz; > - u32 tpq_buf_pg_sz; > + u32 llm_buf_pg_sz; > u32 chunk_sz; /* chunk size in non multihop mode */ > u64 flags; > u16 default_ceq_max_cnt; > diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c > index a3f7dc5..e105e21 100644 > --- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c > +++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c > @@ -2062,7 +2062,7 @@ static void set_hem_page_size(struct hns_roce_dev *hr_dev) > caps->eqe_buf_pg_sz = 0; > > /* Link Table */ > - caps->tsq_buf_pg_sz = 0; > + caps->llm_buf_pg_sz = 0; > > /* MR */ > caps->pbl_ba_pg_sz = HNS_ROCE_BA_PG_SZ_SUPPORTED_16K; > @@ -2478,43 +2478,16 @@ static int hns_roce_v2_profile(struct hns_roce_dev *hr_dev) > return ret; > } > > -static int hns_roce_config_link_table(struct hns_roce_dev *hr_dev, > - enum hns_roce_link_table_type type) > +static void config_llm_table(struct hns_roce_buf *data_buf, void *cfg_buf) > { > - struct hns_roce_cmq_desc desc[2]; > - struct hns_roce_cmq_req *r_a = (struct hns_roce_cmq_req *)desc[0].data; > - struct hns_roce_cmq_req *r_b = (struct hns_roce_cmq_req *)desc[1].data; > - struct hns_roce_v2_priv *priv = hr_dev->priv; > - struct hns_roce_link_table *link_tbl; > - enum hns_roce_opcode_type opcode; > u32 i, next_ptr, page_num; > - struct hns_roce_buf *buf; > + __le64 *entry = cfg_buf; > dma_addr_t addr; > - __le64 *entry; > u64 val; > > - switch (type) { > - case TSQ_LINK_TABLE: > - link_tbl = &priv->tsq; > - opcode = HNS_ROCE_OPC_CFG_EXT_LLM; > - break; > - case TPQ_LINK_TABLE: > - link_tbl = &priv->tpq; > - opcode = HNS_ROCE_OPC_CFG_TMOUT_LLM; > - break; > - default: > - return -EINVAL; > - } > - > - /* Setup data table block address to link table entry */ > - buf = link_tbl->buf; > - page_num = buf->npages; > - if (WARN_ON(page_num > HNS_ROCE_V2_EXT_LLM_MAX_DEPTH)) > - return -EINVAL; You added these lines in previous patch. Please structure the patches in such way that they don't need to add->delete in same series. Thanks