From: Lijun Ou <oulijun@huawei.com>
To: <dledford@redhat.com>, <jgg@ziepe.ca>
Cc: <leon@kernel.org>, <linux-rdma@vger.kernel.org>, <linuxarm@huawei.com>
Subject: [PATCH V4 for-next 04/14] RDMA/hns: Remove unnessary init for cmq reg
Date: Thu, 8 Aug 2019 22:53:44 +0800 [thread overview]
Message-ID: <1565276034-97329-5-git-send-email-oulijun@huawei.com> (raw)
In-Reply-To: <1565276034-97329-1-git-send-email-oulijun@huawei.com>
From: Yixian Liu <liuyixian@huawei.com>
There is no need to init the enable bit of cmq.
Signed-off-by: Yixian Liu <liuyixian@huawei.com>
---
drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 6 ++----
drivers/infiniband/hw/hns/hns_roce_hw_v2.h | 2 --
2 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c
index 6dff7e2..eedafd6 100644
--- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c
+++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c
@@ -887,8 +887,7 @@ static void hns_roce_cmq_init_regs(struct hns_roce_dev *hr_dev, bool ring_type)
roce_write(hr_dev, ROCEE_TX_CMQ_BASEADDR_H_REG,
upper_32_bits(dma));
roce_write(hr_dev, ROCEE_TX_CMQ_DEPTH_REG,
- (ring->desc_num >> HNS_ROCE_CMQ_DESC_NUM_S) |
- HNS_ROCE_CMQ_ENABLE);
+ ring->desc_num >> HNS_ROCE_CMQ_DESC_NUM_S);
roce_write(hr_dev, ROCEE_TX_CMQ_HEAD_REG, 0);
roce_write(hr_dev, ROCEE_TX_CMQ_TAIL_REG, 0);
} else {
@@ -896,8 +895,7 @@ static void hns_roce_cmq_init_regs(struct hns_roce_dev *hr_dev, bool ring_type)
roce_write(hr_dev, ROCEE_RX_CMQ_BASEADDR_H_REG,
upper_32_bits(dma));
roce_write(hr_dev, ROCEE_RX_CMQ_DEPTH_REG,
- (ring->desc_num >> HNS_ROCE_CMQ_DESC_NUM_S) |
- HNS_ROCE_CMQ_ENABLE);
+ ring->desc_num >> HNS_ROCE_CMQ_DESC_NUM_S);
roce_write(hr_dev, ROCEE_RX_CMQ_HEAD_REG, 0);
roce_write(hr_dev, ROCEE_RX_CMQ_TAIL_REG, 0);
}
diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.h b/drivers/infiniband/hw/hns/hns_roce_hw_v2.h
index 478f5a5..58931b5 100644
--- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.h
+++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.h
@@ -126,8 +126,6 @@
#define HNS_ROCE_CMD_FLAG_ERR_INTR BIT(HNS_ROCE_CMD_FLAG_ERR_INTR_SHIFT)
#define HNS_ROCE_CMQ_DESC_NUM_S 3
-#define HNS_ROCE_CMQ_EN_B 16
-#define HNS_ROCE_CMQ_ENABLE BIT(HNS_ROCE_CMQ_EN_B)
#define HNS_ROCE_CMQ_SCC_CLR_DONE_CNT 5
--
1.9.1
next prev parent reply other threads:[~2019-08-08 14:58 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-08 14:53 [PATCH V4 for-next 00/14] Updates for 5.3-rc2 Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 01/14] RDMA/hns: Encapsulate some lines for setting sq size in user mode Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 02/14] RDMA/hns: Optimize hns_roce_modify_qp function Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 03/14] RDMA/hns: Update the prompt message for creating and destroy qp Lijun Ou
2019-08-12 14:47 ` Doug Ledford
2019-08-08 14:53 ` Lijun Ou [this message]
2019-08-08 14:53 ` [PATCH V4 for-next 05/14] RDMA/hns: Clean up unnecessary initial assignment Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 06/14] RDMA/hns: Update some comments style Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 07/14] RDMA/hns: Handling the error return value of hem function Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 08/14] RDMA/hns: Split bool statement and assign statement Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 09/14] RDMA/hns: Refactor irq request code Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 10/14] RDMA/hns: Remove unnecessary kzalloc Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 11/14] RDMA/hns: Refactor hns_roce_v2_set_hem for hip08 Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 12/14] RDMA/hns: Remove redundant print in hns_roce_v2_ceq_int() Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 13/14] RDMA/hns: Disable alw_lcl_lpbk of SSU Lijun Ou
2019-08-08 14:53 ` [PATCH V4 for-next 14/14] RDMA/hns: Use the new APIs for printing log Lijun Ou
2019-08-12 14:48 ` Doug Ledford
2019-08-13 9:13 ` oulijun
2019-08-13 9:31 ` oulijun
2019-08-13 13:33 ` Doug Ledford
2019-08-12 14:48 ` [PATCH V4 for-next 00/14] Updates for 5.3-rc2 Doug Ledford
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1565276034-97329-5-git-send-email-oulijun@huawei.com \
--to=oulijun@huawei.com \
--cc=dledford@redhat.com \
--cc=jgg@ziepe.ca \
--cc=leon@kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=linuxarm@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).