From: Jijie Shao <shaojijie@huawei.com>
To: <netdev@vger.kernel.org>
Cc: <yisen.zhuang@huawei.com>, <salil.mehta@huawei.com>,
<davem@davemloft.net>, <edumazet@google.com>, <kuba@kernel.org>,
<pabeni@redhat.com>, <lanhao@huawei.com>, <shaojijie@huawei.com>,
<chenhao418@huawei.com>, <wangjie125@huawei.com>,
<shenjian15@huawei.com>
Subject: [PATCH net 3/4] net: hns3: fix wrong tc bandwidth weight data issue
Date: Thu, 20 Jul 2023 10:05:09 +0800 [thread overview]
Message-ID: <20230720020510.2223815-4-shaojijie@huawei.com> (raw)
In-Reply-To: <20230720020510.2223815-1-shaojijie@huawei.com>
Currently, the weight saved by the driver is used as the query result,
which may be different from the actual weight in the register.
Therefore, the register value read from the firmware is used
as the query result
Fixes: 0e32038dc856 ("net: hns3: refactor dump tc of debugfs")
Signed-off-by: Jijie Shao <shaojijie@huawei.com>
---
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_debugfs.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_debugfs.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_debugfs.c
index 233c132dc513..409db2e70965 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_debugfs.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_debugfs.c
@@ -693,8 +693,7 @@ static int hclge_dbg_dump_tc(struct hclge_dev *hdev, char *buf, int len)
for (i = 0; i < HNAE3_MAX_TC; i++) {
sch_mode_str = ets_weight->tc_weight[i] ? "dwrr" : "sp";
pos += scnprintf(buf + pos, len - pos, "%u %4s %3u\n",
- i, sch_mode_str,
- hdev->tm_info.pg_info[0].tc_dwrr[i]);
+ i, sch_mode_str, ets_weight->tc_weight[i]);
}
return 0;
--
2.30.0
next prev parent reply other threads:[~2023-07-20 2:08 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-20 2:05 [PATCH net 0/4] There are some bugfix for the HNS3 ethernet driver Jijie Shao
2023-07-20 2:05 ` [PATCH net 1/4] net: hns3: fix the imp capability bit cannot exceed 32 bits issue Jijie Shao
2023-07-20 2:05 ` [PATCH net 2/4] net: hns3: add tm flush when setting tm Jijie Shao
2023-07-20 2:05 ` Jijie Shao [this message]
2023-07-20 2:05 ` [PATCH net 4/4] net: hns3: fix wrong bw weight of disabled tc issue Jijie Shao
2023-07-21 11:26 ` [PATCH net 0/4] There are some bugfix for the HNS3 ethernet driver Simon Horman
2023-07-24 8:40 ` patchwork-bot+netdevbpf
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=20230720020510.2223815-4-shaojijie@huawei.com \
--to=shaojijie@huawei.com \
--cc=chenhao418@huawei.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=lanhao@huawei.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=salil.mehta@huawei.com \
--cc=shenjian15@huawei.com \
--cc=wangjie125@huawei.com \
--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).