DPDK patches and discussions
 help / color / mirror / Atom feed
From: Jie Hai <haijie1@huawei.com>
To: <dev@dpdk.org>, <thomas@monjalon.net>, <ferruh.yigit@amd.com>,
	Yisen Zhuang <yisen.zhuang@huawei.com>,
	Chengwen Feng <fengchengwen@huawei.com>
Cc: <lihuisong@huawei.com>, <haijie1@huawei.com>
Subject: [PATCH] net/hns3: fix variable type
Date: Mon, 21 Oct 2024 10:00:40 +0800	[thread overview]
Message-ID: <20241021020040.24805-1-haijie1@huawei.com> (raw)

The patch fixes variable type in case of data trunction.

Fixes: dd4b8bba785f ("net/hns3: support reporting names of registers")
Cc: stable@dpdk.org

Signed-off-by: Jie Hai <haijie1@huawei.com>
---
 drivers/net/hns3/hns3_regs.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/hns3/hns3_regs.c b/drivers/net/hns3/hns3_regs.c
index e8bc7fbc66e1..be6929738942 100644
--- a/drivers/net/hns3/hns3_regs.c
+++ b/drivers/net/hns3/hns3_regs.c
@@ -1178,9 +1178,9 @@ hns3_direct_access_tqp_regs_help(struct hns3_hw *hw, struct rte_dev_reg_info *re
 				 uint32_t modules, enum hns3_reg_modules idx)
 {
 	const struct hns3_dirt_reg_entry *reg_list;
-	uint16_t tqp_num, reg_offset;
+	uint32_t reg_num, i, j, reg_offset;
 	uint32_t *data = regs->data;
-	uint32_t reg_num, i, j;
+	uint16_t tqp_num;
 
 	if ((modules & HNS3_MODULE_MASK(idx)) == 0)
 		return;
-- 
2.22.0


             reply	other threads:[~2024-10-21  2:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-21  2:00 Jie Hai [this message]
2024-10-22  4:01 ` [PATCH v2 0/2] net/hns3: bugfix on register dump Jie Hai
2024-10-22  4:01   ` [PATCH v2 1/2] net/hns3: fix variable type Jie Hai
2024-10-22  6:32     ` fengchengwen
2024-10-23  6:32     ` lihuisong (C)
2024-10-22  4:01   ` [PATCH v2 2/2] net/hns3: fix pointer offset Jie Hai
2024-10-22  6:32     ` fengchengwen
2024-10-23  6:32     ` lihuisong (C)

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=20241021020040.24805-1-haijie1@huawei.com \
    --to=haijie1@huawei.com \
    --cc=dev@dpdk.org \
    --cc=fengchengwen@huawei.com \
    --cc=ferruh.yigit@amd.com \
    --cc=lihuisong@huawei.com \
    --cc=thomas@monjalon.net \
    --cc=yisen.zhuang@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).