From: Xiaoyun Wang Date: Fri, 1 Nov 2019 13:36:43 +0000 (+0800) Subject: net/hinic: fix offload info calculating for TSO X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=203911b1dc33db7b16e598c7ce36229652bc0d1a;p=dpdk.git net/hinic: fix offload info calculating for TSO For VXLAN TSO offload, PMD calculates offload info err due to the wrong branch, which can cause hardware failed. Fixes: c3ba1f0f20cd ("net/hinic: support inner L3 checksum offload") Signed-off-by: Xiaoyun Wang --- diff --git a/drivers/net/hinic/hinic_pmd_tx.c b/drivers/net/hinic/hinic_pmd_tx.c index bdbb0f4a4c..985540a935 100644 --- a/drivers/net/hinic/hinic_pmd_tx.c +++ b/drivers/net/hinic/hinic_pmd_tx.c @@ -811,7 +811,8 @@ hinic_tx_offload_pkt_prepare(struct rte_mbuf *m, if (ol_flags & PKT_TX_TUNNEL_VXLAN) { if ((ol_flags & PKT_TX_OUTER_IP_CKSUM) || - (ol_flags & PKT_TX_OUTER_IPV6)) { + (ol_flags & PKT_TX_OUTER_IPV6) || + (ol_flags & PKT_TX_TCP_SEG)) { inner_l3_offset = m->l2_len + m->outer_l2_len + m->outer_l3_len; off_info->outer_l2_len = m->outer_l2_len;