From: Wenpeng Liang liangwenpeng@huawei.com
driver inclusion category: Bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I61RNU
----------------------------------------------------------
Use urt to run the open xrc qp business, and the following error occurs: Create qp failed.
because the driver does not have an ex_cmd flag, related ioctl() or syscall() will fail to execute. so add open xrc qp cmd flag.
Fixes: ae394640bc89 ("RDMA/hns: Add support for XRC on HIP09") Signed-off-by: Wenpeng Liang liangwenpeng@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_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/infiniband/hw/hns/hns_roce_main.c b/drivers/infiniband/hw/hns/hns_roce_main.c index 43ab590f9aac..e3b188b2bb4c 100644 --- a/drivers/infiniband/hw/hns/hns_roce_main.c +++ b/drivers/infiniband/hw/hns/hns_roce_main.c @@ -708,7 +708,8 @@ static int hns_roce_register_device(struct hns_roce_dev *hr_dev) ib_dev->uverbs_cmd_mask |= (1ULL << IB_USER_VERBS_CMD_OPEN_XRCD) | (1ULL << IB_USER_VERBS_CMD_CLOSE_XRCD) | - (1ULL << IB_USER_VERBS_CMD_CREATE_XSRQ); + (1ULL << IB_USER_VERBS_CMD_CREATE_XSRQ) | + (1ULL << IB_USER_VERBS_CMD_OPEN_QP); ib_set_device_ops(ib_dev, &hns_roce_dev_xrcd_ops); }