DPDK patches and discussions
 help / color / mirror / Atom feed
From: Ziyang Xuan <xuanziyang2@huawei.com>
To: <dev@dpdk.org>
Cc: <ferruh.yigit@intel.com>, <cloud.wangxiaoyun@huawei.com>,
	<wulike1@huawei.com>, <shahar.belkar@huawei.com>,
	<luoxianjun@huawei.com>, <tanya.brokhman@huawei.com>,
	Ziyang Xuan <xuanziyang2@huawei.com>
Subject: [dpdk-dev] [PATCH v1 1/1] net/hinic: solve lgtm errors reporting
Date: Tue, 16 Jul 2019 11:59:28 +0800	[thread overview]
Message-ID: <1563249568-35436-1-git-send-email-xuanziyang2@huawei.com> (raw)

There are some implicit downcast errors in TX offload
information parsing. This patch is to solve these errors.

Signed-off-by: Ziyang Xuan <xuanziyang2@huawei.com>
---
 drivers/net/hinic/hinic_pmd_tx.h | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/net/hinic/hinic_pmd_tx.h b/drivers/net/hinic/hinic_pmd_tx.h
index 8b361cf..8a3df27 100644
--- a/drivers/net/hinic/hinic_pmd_tx.h
+++ b/drivers/net/hinic/hinic_pmd_tx.h
@@ -29,19 +29,20 @@ enum sq_wqe_type {
 struct hinic_tx_offload_info {
 	u8 outer_l2_len;
 	u8 outer_l3_type;
-	u8 outer_l3_len;
+	u16 outer_l3_len;
 
 	u8 inner_l2_len;
 	u8 inner_l3_type;
-	u8 inner_l3_len;
+	u16 inner_l3_len;
 
 	u8 tunnel_length;
 	u8 tunnel_type;
 	u8 inner_l4_type;
 	u8 inner_l4_len;
 
-	u8 payload_offset;
+	u16 payload_offset;
 	u8 inner_l4_tcp_udp;
+	u8 rsvd0;
 };
 
 /* tx sge info */
-- 
1.8.3.1


             reply	other threads:[~2019-07-16  3:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-16  3:59 Ziyang Xuan [this message]
2019-07-16 14:19 ` Ferruh Yigit

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=1563249568-35436-1-git-send-email-xuanziyang2@huawei.com \
    --to=xuanziyang2@huawei.com \
    --cc=cloud.wangxiaoyun@huawei.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=luoxianjun@huawei.com \
    --cc=shahar.belkar@huawei.com \
    --cc=tanya.brokhman@huawei.com \
    --cc=wulike1@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).