All of lore.kernel.org
 help / color / mirror / Atom feed
From: Junxian Huang <huangjunxian6@hisilicon.com>
To: <jgg@ziepe.ca>, <leon@kernel.org>
Cc: <linux-rdma@vger.kernel.org>, <linuxarm@huawei.com>,
	<linux-kernel@vger.kernel.org>, <huangjunxian6@hisilicon.com>
Subject: [PATCH for-next 10/10] RDMA/hns: Modify the print level of CQE error
Date: Fri, 12 Apr 2024 17:16:16 +0800	[thread overview]
Message-ID: <20240412091616.370789-11-huangjunxian6@hisilicon.com> (raw)
In-Reply-To: <20240412091616.370789-1-huangjunxian6@hisilicon.com>

From: Chengchang Tang <tangchengchang@huawei.com>

Too much print may lead to a panic in kernel. Change ibdev_err() to
ibdev_err_ratelimited(), and change the printing level of cqe dump
to debug level.

Fixes: 7c044adca272 ("RDMA/hns: Simplify the cqe code of poll cq")
Signed-off-by: Chengchang Tang <tangchengchang@huawei.com>
Signed-off-by: Junxian Huang <huangjunxian6@hisilicon.com>
---
 drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c
index 5d526b5c4b81..4287818a737f 100644
--- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c
+++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c
@@ -3713,8 +3713,9 @@ static void get_cqe_status(struct hns_roce_dev *hr_dev, struct hns_roce_qp *qp,
 		   wc->status == IB_WC_WR_FLUSH_ERR))
 		return;
 
-	ibdev_err(&hr_dev->ib_dev, "error cqe status 0x%x:\n", cqe_status);
-	print_hex_dump(KERN_ERR, "", DUMP_PREFIX_NONE, 16, 4, cqe,
+	ibdev_err_ratelimited(&hr_dev->ib_dev, "error cqe status 0x%x:\n",
+			      cqe_status);
+	print_hex_dump(KERN_DEBUG, "", DUMP_PREFIX_NONE, 16, 4, cqe,
 		       cq->cqe_size, false);
 	wc->vendor_err = hr_reg_read(cqe, CQE_SUB_STATUS);
 
-- 
2.30.0


  parent reply	other threads:[~2024-04-12  9:20 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-12  9:16 [PATCH for-next 00/10] RDMA/hns: Bugfixes and cleanups Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 01/10] RDMA/hns: Use macro instead of magic number Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 02/10] RDMA/hns: Remove unused parameters and variables Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 03/10] RDMA/hns: Add max_ah and cq moderation capacities in query_device() Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 04/10] RDMA/hns: Fix deadlock on SRQ async events Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 05/10] RDMA/hns: Fix UAF for cq async event Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 06/10] RDMA/hns: Fix mismatch exception rollback Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 07/10] RDMA/hns: Fix GMV table pagesize Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 08/10] RDMA/hns: Add mutex_destroy() Junxian Huang
2024-04-12  9:16 ` [PATCH for-next 09/10] RDMA/hns: Use complete parentheses in macros Junxian Huang
2024-04-12  9:16 ` Junxian Huang [this message]
2024-04-16 12:07 ` [PATCH for-next 00/10] RDMA/hns: Bugfixes and cleanups Leon Romanovsky

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=20240412091616.370789-11-huangjunxian6@hisilicon.com \
    --to=huangjunxian6@hisilicon.com \
    --cc=jgg@ziepe.ca \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.