dev.dpdk.org archive mirror
 help / color / mirror / Atom feed
From: Olivier MATZ <olivier.matz-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
To: Jijiang Liu <jijiang.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>,
	dev-VfR2kkLFssw@public.gmane.org
Subject: Re: [PATCH v3 2/4] mbuf:change PKT_TX_IPV4 and PKT_TX_IPV6 definition
Date: Fri, 28 Nov 2014 10:37:14 +0100	[thread overview]
Message-ID: <5478424A.8030008@6wind.com> (raw)
In-Reply-To: <1417107801-9544-3-git-send-email-jijiang.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>



On 11/27/2014 06:03 PM, Jijiang Liu wrote:
> It will avoid to send a packet with a bad info:
>   - we receive a Ether/IP6/IP4/L4/data packet
>   - the driver sets PKT_RX_IPV6_HDR
>   - the stack decapsulates IP6
>   - the stack sends the packet, it has the PKT_TX_IPV6 flag but it's an IPv4 packet.
> 
> Signed-off-by: Jijiang Liu <jijiang.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
> ---
>  lib/librte_mbuf/rte_mbuf.h |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
> index 22ee555..f6b3185 100644
> --- a/lib/librte_mbuf/rte_mbuf.h
> +++ b/lib/librte_mbuf/rte_mbuf.h
> @@ -127,10 +127,10 @@ extern "C" {
>  #define PKT_TX_VLAN_PKT      (1ULL << 55) /**< TX packet is a 802.1q VLAN packet. */
>  
>  /** Tell the NIC it's an IPv4 packet. Required for L4 checksum offload or TSO. */
> -#define PKT_TX_IPV4          PKT_RX_IPV4_HDR
> +#define PKT_TX_IPV4          (1ULL << 56)
>  
>  /** Tell the NIC it's an IPv6 packet. Required for L4 checksum offload or TSO. */
> -#define PKT_TX_IPV6          PKT_RX_IPV6_HDR
> +#define PKT_TX_IPV6          (1ULL << 57)
>  
>  /** Outer IP cksum of TX pkt. computed by NIC for tunneling packet */
>  #define PKT_TX_OUTER_IP_CKSUM   (1ULL << 58)
> 

Acked-by: Olivier Matz <olivier.matz-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>

  parent reply	other threads:[~2014-11-28  9:37 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-27 17:03 [PATCH v3 0/4] i40e VXLAN TX checksum rework Jijiang Liu
     [not found] ` <1417107801-9544-1-git-send-email-jijiang.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-11-27 17:03   ` [PATCH v3 1/4] mbuf:add three TX offload flags and change three fields Jijiang Liu
     [not found]     ` <1417107801-9544-2-git-send-email-jijiang.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-11-28  9:36       ` Olivier MATZ
     [not found]         ` <54784232.8030707-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
2014-11-28 10:27           ` Ananyev, Konstantin
2014-11-28 10:33           ` Liu, Jijiang
     [not found]             ` <1ED644BD7E0A5F4091CF203DAFB8E4CC01D9F2B9-0J0gbvR4kThpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-11-28 10:40               ` Ananyev, Konstantin
     [not found]                 ` <2601191342CEEE43887BDE71AB977258213BB218-kPTMFJFq+rEu0RiL9chJVbfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-11-28 11:00                   ` Olivier MATZ
     [not found]                     ` <547855C9.80507-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
2014-11-28 11:13                       ` Ananyev, Konstantin
     [not found]                         ` <2601191342CEEE43887BDE71AB977258213BB258-kPTMFJFq+rEu0RiL9chJVbfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-11-28 11:18                           ` Olivier MATZ
     [not found]                             ` <54785A15.1090301-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
2014-11-28 15:46                               ` Ananyev, Konstantin
2014-11-27 17:03   ` [PATCH v3 2/4] mbuf:change PKT_TX_IPV4 and PKT_TX_IPV6 definition Jijiang Liu
     [not found]     ` <1417107801-9544-3-git-send-email-jijiang.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-11-28  9:37       ` Olivier MATZ [this message]
2014-11-27 17:03   ` [PATCH v3 3/4] i40e:PMD change for VXLAN TX checksum Jijiang Liu
2014-11-27 17:03   ` [PATCH v3 4/4] testpmd:rework csum forward engine Jijiang Liu
     [not found]     ` <1417107801-9544-5-git-send-email-jijiang.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-11-28  9:50       ` Olivier MATZ
     [not found]         ` <54784562.90906-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
2014-11-28 10:10           ` Thomas Monjalon
2014-11-27 17:24   ` [PATCH v3 0/4] i40e VXLAN TX checksum rework Ananyev, Konstantin

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=5478424A.8030008@6wind.com \
    --to=olivier.matz-pdr9zngts4eavxtiumwx3w@public.gmane.org \
    --cc=dev-VfR2kkLFssw@public.gmane.org \
    --cc=jijiang.liu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
    /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).