From: Jijie Shao <shaojijie@huawei.com>
To: Simon Horman <horms@kernel.org>
Cc: <shaojijie@huawei.com>, <yisen.zhuang@huawei.com>,
<salil.mehta@huawei.com>, <davem@davemloft.net>,
<edumazet@google.com>, <kuba@kernel.org>, <pabeni@redhat.com>,
<shenjian15@huawei.com>, <wangjie125@huawei.com>,
<liuyonglong@huawei.com>, <lanhao@huawei.com>,
<wangpeiyang1@huawei.com>, <netdev@vger.kernel.org>,
<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH V2 net-next 1/3] net: hns3: add command queue trace for hns3
Date: Sat, 16 Dec 2023 09:42:54 +0800 [thread overview]
Message-ID: <ad6b7294-049b-475a-bd55-75f61d72d258@huawei.com> (raw)
In-Reply-To: <20231214210434.GU5817@kernel.org>
on 2023/12/15 5:04, Simon Horman wrote:
> On Thu, Dec 14, 2023 at 10:11:33PM +0800, Jijie Shao wrote:
>> From: Hao Lan <lanhao@huawei.com>
>> ...
>> @@ -470,10 +470,14 @@ static int hclge_comm_cmd_check_result(struct hclge_comm_hw *hw,
>> int hclge_comm_cmd_send(struct hclge_comm_hw *hw, struct hclge_desc *desc,
>> int num)
>> {
>> + bool is_special = hclge_comm_is_special_opcode(desc->opcode);
>> struct hclge_comm_cmq_ring *csq = &hw->cmq.csq;
>> int ret;
>> int ntc;
> hclge_comm_is_special_opcode takes a u16 value as it's argument,
> but the type of desc->opcode is __le16. So perhaps this should be
> (completely untested!):
>
> struct hclge_comm_cmq_ring *csq = &hw->cmq.csq;
> bool is_special;
> ...
>
> is_special = hclge_comm_is_special_opcode(le16_to_cpu(desc->opcode));
>
> Flagged by Sparse.
Thank you,
it will be fixed in v3
Jijie
next prev parent reply other threads:[~2023-12-16 1:42 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-14 14:11 [PATCH V2 net-next 0/3] There are some features for the HNS3 ethernet driver Jijie Shao
2023-12-14 14:11 ` [PATCH V2 net-next 1/3] net: hns3: add command queue trace for hns3 Jijie Shao
2023-12-14 21:04 ` Simon Horman
2023-12-16 1:42 ` Jijie Shao [this message]
2023-12-14 14:11 ` [PATCH V2 net-next 2/3] net: hns3: dump more reg info based on ras mod Jijie Shao
2023-12-15 8:01 ` Simon Horman
2023-12-16 1:37 ` Jijie Shao
2023-12-14 14:11 ` [PATCH V2 net-next 3/3] net: hns3: support dump pfc frame statistics in tx timeout log Jijie Shao
2023-12-15 8:03 ` Simon Horman
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=ad6b7294-049b-475a-bd55-75f61d72d258@huawei.com \
--to=shaojijie@huawei.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=lanhao@huawei.com \
--cc=linux-kernel@vger.kernel.org \
--cc=liuyonglong@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=wangpeiyang1@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
all inboxes | Powered by JetHome®