diff options
author | Shaobo Xu <xushaobo2@huawei.com> | 2016-11-30 00:10:29 +0100 |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2016-12-03 20:20:42 +0100 |
commit | afb6b092d6507b17c75df394b1d1b2a6e1674627 (patch) | |
tree | 06c7c9341d14ee59b350d0cc9b66bc3e0c02008a /drivers/infiniband/hw/hns/hns_roce_common.h | |
parent | IB/hns: Delete the redundant memset operation (diff) | |
download | linux-afb6b092d6507b17c75df394b1d1b2a6e1674627.tar.xz linux-afb6b092d6507b17c75df394b1d1b2a6e1674627.zip |
IB/hns: Fix the bug when free cq
If the resources of cq are freed while executing the user case, hardware
can not been notified in hip06 SoC. Then hardware will hold on when it
writes the cq buffer which has been released.
In order to slove this problem, RoCE driver checks the CQE counter, and
ensure that the outstanding CQE have been written. Then the cq buffer
can be released.
Signed-off-by: Shaobo Xu <xushaobo2@huawei.com>
Reviewed-by: Wei Hu (Xavier) <xavier.huwei@huawei.com>
Signed-off-by: Salil Mehta <salil.mehta@huawei.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/hw/hns/hns_roce_common.h')
-rw-r--r-- | drivers/infiniband/hw/hns/hns_roce_common.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/hns/hns_roce_common.h b/drivers/infiniband/hw/hns/hns_roce_common.h index a0556323a678..4af403e1348c 100644 --- a/drivers/infiniband/hw/hns/hns_roce_common.h +++ b/drivers/infiniband/hw/hns/hns_roce_common.h @@ -354,6 +354,8 @@ #define ROCEE_SDB_ISSUE_PTR_REG 0x758 #define ROCEE_SDB_SEND_PTR_REG 0x75C +#define ROCEE_CAEP_CQE_WCMD_EMPTY 0x850 +#define ROCEE_SCAEP_WR_CQE_CNT 0x8D0 #define ROCEE_SDB_INV_CNT_REG 0x9A4 #define ROCEE_SDB_RETRY_CNT_REG 0x9AC #define ROCEE_TSP_BP_ST_REG 0x9EC |