diff options
author | Lang Cheng <chenglang@huawei.com> | 2021-08-21 17:53:27 +0800 |
---|---|---|
committer | Jason Gunthorpe <jgg@nvidia.com> | 2021-08-23 13:45:12 -0300 |
commit | f8c549afd1e76ad78b1d044a307783c9b94ae3ab (patch) | |
tree | 9eaecdcd60bb33ffb7c4383a45150da6d48d559a /drivers/infiniband | |
parent | 260f64a40198309008026447f7fda277a73ed8c3 (diff) |
RDMA/hns: Ownerbit mode add control field
The ownerbit mode is for external card mode. Make it controlled by the
firmware.
Fixes: aba457ca890c ("RDMA/hns: Support owner mode doorbell")
Link: https://lore.kernel.org/r/1629539607-33217-4-git-send-email-liangwenpeng@huawei.com
Signed-off-by: Lang Cheng <chenglang@huawei.com>
Signed-off-by: Wenpeng Liang <liangwenpeng@huawei.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c index 5d594c05fc0f..d00be78a2931 100644 --- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c +++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c @@ -4108,6 +4108,9 @@ static void modify_qp_reset_to_init(struct ib_qp *ibqp, if (hr_qp->en_flags & HNS_ROCE_QP_CAP_RQ_RECORD_DB) hr_reg_enable(context, QPC_RQ_RECORD_EN); + if (hr_qp->en_flags & HNS_ROCE_QP_CAP_OWNER_DB) + hr_reg_enable(context, QPC_OWNER_MODE); + hr_reg_write(context, QPC_RQ_DB_RECORD_ADDR_L, lower_32_bits(hr_qp->rdb.dma) >> 1); hr_reg_write(context, QPC_RQ_DB_RECORD_ADDR_H, |