From: Yixing Liu liuyixing1@huawei.com
driver inclusion category: Bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I61F1Q
--------------------------------------------------------------
Running roce v1 business on fpga, the following error occurs: hns3 0000:35:00.0 hns_0: local work queue 0x2 catast error, sub_event type is: 4
This is because the sl transmitted by the roce v1 service driver after set dscp is incorrect, which makes the sl of db inconsistent with the sl of qpc, resulting in an sl error on the hardware.
Fixes: 11ef2ec6aa7c ("RDMA/hns: Support DSCP of userspace") Signed-off-by: Yixing Liu liuyixing1@huawei.com Reviewed-by: Yangyang Li liyangyang20@huawei.com Reviewed-by: Yue Haibing yuehaibing@huawei.com Signed-off-by: Zheng Zengkai zhengzengkai@huawei.com --- drivers/infiniband/hw/hns/hns_roce_qp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/infiniband/hw/hns/hns_roce_qp.c b/drivers/infiniband/hw/hns/hns_roce_qp.c index cbe7d37430c7..df5bebc5e1c1 100644 --- a/drivers/infiniband/hw/hns/hns_roce_qp.c +++ b/drivers/infiniband/hw/hns/hns_roce_qp.c @@ -1384,7 +1384,7 @@ int hns_roce_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr,
if (udata && udata->outlen) { resp.tc_mode = hr_qp->tc_mode; - resp.priority = hr_qp->priority; + resp.priority = hr_qp->sl; ret = ib_copy_to_udata(udata, &resp, min(udata->outlen, sizeof(resp))); if (ret)