All of lore.kernel.org
 help / color / mirror / Atom feed
From: Xueming Li <xuemingl@mellanox.com>
To: Wenzhuo Lu <wenzhuo.lu@intel.com>,
	Jingjing Wu <jingjing.wu@intel.com>,
	Thomas Monjalon <thomas@monjalon.net>,
	Adrien Mazarguil <adrien.mazarguil@6wind.com>
Cc: Xueming Li <xuemingl@mellanox.com>,
	Nelio Laranjeiro <nelio.laranjeiro@6wind.com>,
	Shahaf Shuler <shahafs@mellanox.com>,
	dev@dpdk.org, Olivier Matz <olivier.matz@6wind.com>
Subject: [PATCH v7 3/5] ethdev: introduce tunnel type MPLS-in-GRE and MPLS-in-UDP
Date: Mon, 23 Apr 2018 20:16:33 +0800	[thread overview]
Message-ID: <20180423121635.32347-4-xuemingl@mellanox.com> (raw)
In-Reply-To: <20180423121635.32347-1-xuemingl@mellanox.com>
In-Reply-To: <20180420115629.112472-1-xuemingl@mellanox.com>

This patch adds new tunnel type for MPLS-in-GRE and MPLS-in-UDP.

MPLS-in-GRE protocol link:
https://tools.ietf.org/html/rfc4023

MPLS-in-UDP protocol link:
https://tools.ietf.org/html/rfc7510

Signed-off-by: Xueming Li <xuemingl@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_mbuf/rte_mbuf_ptype.c |  2 ++
 lib/librte_mbuf/rte_mbuf_ptype.h | 34 ++++++++++++++++++++++++++++++++++
 2 files changed, 36 insertions(+)

diff --git a/lib/librte_mbuf/rte_mbuf_ptype.c b/lib/librte_mbuf/rte_mbuf_ptype.c
index 49106c7df..d7835e283 100644
--- a/lib/librte_mbuf/rte_mbuf_ptype.c
+++ b/lib/librte_mbuf/rte_mbuf_ptype.c
@@ -66,6 +66,8 @@ const char *rte_get_ptype_tunnel_name(uint32_t ptype)
 	case RTE_PTYPE_TUNNEL_ESP: return "TUNNEL_ESP";
 	case RTE_PTYPE_TUNNEL_L2TP: return "TUNNEL_L2TP";
 	case RTE_PTYPE_TUNNEL_VXLAN_GPE: return "TUNNEL_VXLAN_GPE";
+	case RTE_PTYPE_TUNNEL_MPLS_IN_UDP: return "TUNNEL_MPLS_IN_UDP";
+	case RTE_PTYPE_TUNNEL_MPLS_IN_GRE: return "TUNNEL_MPLS_IN_GRE";
 	default: return "TUNNEL_UNKNOWN";
 	}
 }
diff --git a/lib/librte_mbuf/rte_mbuf_ptype.h b/lib/librte_mbuf/rte_mbuf_ptype.h
index 7caf83312..79ea31425 100644
--- a/lib/librte_mbuf/rte_mbuf_ptype.h
+++ b/lib/librte_mbuf/rte_mbuf_ptype.h
@@ -436,6 +436,40 @@ extern "C" {
  */
 #define RTE_PTYPE_TUNNEL_VXLAN_GPE          0x0000b000
 /**
+ * MPLS-in-GRE tunneling packet type (RFC 4023).
+ *
+ * Packet format:
+ * <'ether type'=0x0800
+ * | 'version'=4, 'protocol'=47
+ * | 'protocol'=0x8847>
+ * or,
+ * <'ether type'=0x0800
+ * | 'version'=4, 'protocol'=47
+ * | 'protocol'=0x8848>
+ * or,
+ * <'ether type'=0x86DD
+ * | 'version'=6, 'protocol'=47
+ * | 'protocol'=0x8847>
+ * or,
+ * <'ether type'=0x86DD
+ * | 'version'=6, 'next header'=47
+ * | 'protocol'=0x8848>
+ */
+#define RTE_PTYPE_TUNNEL_MPLS_IN_GRE       0x0000c000
+/**
+ * MPLS-in-UDP tunneling packet type (RFC 7510).
+ *
+ * Packet format:
+ * <'ether type'=0x0800
+ * | 'version'=4, 'protocol'=17
+ * | 'destination port'=6635>
+ * or,
+ * <'ether type'=0x86DD
+ * | 'version'=6, 'next header'=17
+ * | 'destination port'=6635>
+ */
+#define RTE_PTYPE_TUNNEL_MPLS_IN_UDP      0x0000d000
+/**
  * Mask of tunneling packet types.
  */
 #define RTE_PTYPE_TUNNEL_MASK               0x0000f000
-- 
2.13.3

  parent reply	other threads:[~2018-04-23 12:29 UTC|newest]

Thread overview: 111+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-26 15:09 [PATCH 00/18] MLX5 tunnel Rx offloading Xueming Li
2018-02-26 15:09 ` [PATCH 01/18] ethdev: support tunnel RSS level Xueming Li
2018-02-27 13:09   ` Ferruh Yigit
2018-03-09 11:29   ` [PATCH v1 00/21] MLX5 tunnel Rx offloading Xueming Li
2018-03-09 11:29   ` [PATCH v1 01/21] ethdev: support tunnel RSS level Xueming Li
2018-03-09 11:29   ` [PATCH v1 02/21] app/testpmd: support flow RSS level parsing Xueming Li
2018-03-09 11:29   ` [PATCH v1 03/21] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-03-09 11:29   ` [PATCH v1 04/21] app/testpmd: " Xueming Li
2018-03-09 11:29   ` [PATCH v1 05/21] app/testpmd: add more GRE extension support to csum engine Xueming Li
2018-03-09 11:29   ` [PATCH v1 06/21] net/mlx5: fix tunnel offloads cap query Xueming Li
2018-03-09 11:29   ` [PATCH v1 07/21] net/mlx5: support GRE tunnel flow Xueming Li
2018-03-09 11:29   ` [PATCH v1 08/21] net/mlx5: support L3 vxlan Xueming Li
2018-03-09 11:29   ` [PATCH v1 09/21] net/mlx5: support tunnel inner csum offloads Xueming Li
2018-03-09 11:29   ` [PATCH v1 10/21] net/mlx5: support packet tunnel type Xueming Li
2018-03-09 11:29   ` [PATCH v1 11/21] net/mlx5: split flow RSS handling logic Xueming Li
2018-03-09 11:29   ` [PATCH v1 12/21] net/mlx5: support tunnel RSS level Xueming Li
2018-03-09 11:29   ` [PATCH v1 13/21] net/mlx5: support 16 hardware priorities Xueming Li
2018-03-09 11:29   ` [PATCH v1 14/21] net/mlx5: add hardware flow debug dump Xueming Li
2018-03-09 11:29   ` [PATCH v1 15/21] net/mlx5: fix control flow create failure Xueming Li
2018-03-09 11:29   ` [PATCH v1 16/21] net/mlx5: introduce new tunnel VXLAN-GPE Xueming Li
2018-03-09 11:29   ` [PATCH v1 17/21] net/mlx5: allow flow tunnel ID 0 with outer pattern Xueming Li
2018-03-09 11:29   ` [PATCH v1 18/21] doc: update mlx5 guide on tunnel offloading Xueming Li
2018-03-09 11:29   ` [PATCH v1 19/21] doc: remove announce of ethdev API change for RSS configuration Xueming Li
2018-03-09 11:29   ` [PATCH v1 20/21] ethdev: introduce tunnel type MPLS-in-GRE and MPLS-in-UDP Xueming Li
2018-03-09 11:29   ` [PATCH v1 21/21] net/mlx5: support MPLS-in-GRE and MPLS-in-UDP flow pattern Xueming Li
2018-04-10 13:00   ` [PATCH v2 0/5] introduce new tunnel types Xueming Li
2018-04-10 13:00   ` [PATCH v2 1/5] doc: remove RSS configuration change announcement Xueming Li
2018-04-11  9:57     ` Adrien Mazarguil
2018-04-10 13:00   ` [PATCH v2 2/5] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-11  9:59     ` Adrien Mazarguil
2018-04-11 12:04       ` Xueming(Steven) Li
2018-04-10 13:00   ` [PATCH v2 3/5] ethdev: introduce tunnel type MPLS-in-GRE and MPLS-in-UDP Xueming Li
2018-04-11  9:58     ` Adrien Mazarguil
2018-04-10 13:00   ` [PATCH v2 4/5] app/testpmd: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-10 14:07     ` Nélio Laranjeiro
2018-04-11  9:59     ` Adrien Mazarguil
2018-04-10 13:00   ` [PATCH v2 5/5] app/testpmd: add more GRE extension support to csum engine Xueming Li
2018-04-12  7:33   ` [PATCH v3 0/5] introduce new tunnel types Xueming Li
2018-04-12  7:33   ` [PATCH v3 1/5] doc: remove RSS configuration change announcement Xueming Li
2018-04-12  7:33   ` [PATCH v3 2/5] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-12 12:01     ` Adrien Mazarguil
2018-04-12  7:33   ` [PATCH v3 3/5] ethdev: introduce tunnel type MPLS-in-GRE and MPLS-in-UDP Xueming Li
2018-04-12  7:33   ` [PATCH v3 4/5] app/testpmd: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-12 12:01     ` Adrien Mazarguil
2018-04-12  7:33   ` [PATCH v3 5/5] app/testpmd: add more GRE extension support to csum engine Xueming Li
2018-04-13 11:02   ` [PATCH v4 0/5] introduce new tunnel types Xueming Li
2018-04-16 22:33     ` Thomas Monjalon
2018-04-17 15:04     ` [PATCH v5 0/4] " Xueming Li
2018-04-17 16:05       ` Iremonger, Bernard
2018-04-18 11:55         ` Xueming(Steven) Li
2018-04-18 15:11           ` Iremonger, Bernard
2018-04-19 14:24             ` Xueming(Steven) Li
2018-04-19 14:57               ` Thomas Monjalon
2018-04-19 19:56                 ` Ferruh Yigit
2018-04-17 15:04     ` [PATCH v5 1/4] doc: remove RSS configuration change announcement Xueming Li
2018-04-17 15:04     ` [PATCH v5 2/4] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-17 20:56       ` Thomas Monjalon
2018-04-18  8:12         ` Adrien Mazarguil
2018-04-17 15:04     ` [PATCH v5 3/4] app/testpmd: " Xueming Li
2018-04-17 15:04     ` [PATCH v5 4/4] app/testpmd: add more GRE extension support to csum engine Xueming Li
2018-04-17 15:33     ` [PATCH v5 2/4] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-20 11:56     ` [PATCH v6 0/5] introduce new tunnel types Xueming Li
2018-04-23 12:16       ` [PATCH v7 " Xueming Li
2018-04-25 21:31         ` Ferruh Yigit
2018-04-23 12:16       ` [PATCH v7 1/5] doc: remove RSS configuration change announcement Xueming Li
2018-04-23 16:13         ` Ferruh Yigit
2018-04-23 16:56           ` Thomas Monjalon
2018-04-24  5:07           ` Xueming(Steven) Li
2018-04-25 17:38             ` Ferruh Yigit
2018-04-23 12:16       ` [PATCH v7 2/5] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-23 12:16       ` Xueming Li [this message]
2018-04-23 15:15         ` [PATCH v7 3/5] ethdev: introduce tunnel type MPLS-in-GRE and MPLS-in-UDP Thomas Monjalon
2018-04-23 12:16       ` [PATCH v7 4/5] app/testpmd: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-23 12:16       ` [PATCH v7 5/5] app/testpmd: add more GRE extension support to csum engine Xueming Li
2018-04-20 11:56     ` [PATCH v6 1/5] doc: remove RSS configuration change announcement Xueming Li
2018-04-20 11:56     ` [PATCH v6 2/5] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-23  9:43       ` Olivier Matz
2018-04-20 11:56     ` [PATCH v6 3/5] ethdev: introduce tunnel type MPLS-in-GRE and MPLS-in-UDP Xueming Li
2018-04-23  9:43       ` Olivier Matz
2018-04-20 11:56     ` [PATCH v6 4/5] app/testpmd: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-20 11:56     ` [PATCH v6 5/5] app/testpmd: add more GRE extension support to csum engine Xueming Li
2018-04-13 11:02   ` [PATCH v4 1/5] doc: remove RSS configuration change announcement Xueming Li
2018-04-17 15:16     ` Iremonger, Bernard
2018-04-17 15:37       ` Xueming(Steven) Li
2018-04-13 11:02   ` [PATCH v4 2/5] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-16 22:23     ` Thomas Monjalon
2018-04-17  8:54       ` Mohammad Abdul Awal
2018-04-13 11:02   ` [PATCH v4 3/5] ethdev: introduce tunnel type MPLS-in-GRE and MPLS-in-UDP Xueming Li
2018-04-13 11:02   ` [PATCH v4 4/5] app/testpmd: introduce new tunnel VXLAN-GPE Xueming Li
2018-04-13 11:02   ` [PATCH v4 5/5] app/testpmd: add more GRE extension support to csum engine Xueming Li
2018-04-17 15:12     ` Iremonger, Bernard
2018-02-26 15:09 ` [PATCH 02/18] app/testpmd: support flow RSS level parsing Xueming Li
2018-02-27 13:10   ` Ferruh Yigit
2018-03-05 10:36     ` Xueming(Steven) Li
2018-02-26 15:09 ` [PATCH 03/18] ethdev: introduce new tunnel VXLAN-GPE Xueming Li
2018-02-27 15:25   ` Mohammad Abdul Awal
2018-02-26 15:09 ` [PATCH 04/18] app/testpmd: " Xueming Li
2018-02-26 15:09 ` [PATCH 05/18] app/testpmd: add more GRE extension support to csum engine Xueming Li
2018-02-26 15:09 ` [PATCH 06/18] net/mlx5: fix tunnel offloads cap query Xueming Li
2018-02-26 15:09 ` [PATCH 07/18] net/mlx5: support GRE tunnel flow Xueming Li
2018-02-26 15:09 ` [PATCH 08/18] net/mlx5: support L3 vxlan Xueming Li
2018-02-26 15:09 ` [PATCH 09/18] net/mlx5: support tunnel inner csum offloads Xueming Li
2018-02-26 15:09 ` [PATCH 10/18] net/mlx5: support packet tunnel type Xueming Li
2018-02-26 15:09 ` [PATCH 11/18] net/mlx5: split flow RSS handling logic Xueming Li
2018-02-26 15:09 ` [PATCH 12/18] net/mlx5: support tunnel RSS level Xueming Li
2018-02-26 15:09 ` [PATCH 13/18] net/mlx5: support 16 hardware priorities Xueming Li
2018-02-26 15:09 ` [PATCH 14/18] net/mlx5: add hardware flow debug dump Xueming Li
2018-02-26 15:09 ` [PATCH 15/18] net/mlx5: fix control flow create failure Xueming Li
2018-02-26 15:09 ` [PATCH 16/18] net/mlx5: introduce new tunnel VXLAN-GPE Xueming Li
2018-02-26 15:09 ` [PATCH 17/18] net/mlx5: allow flow tunnel ID 0 with outer pattern Xueming Li
2018-02-26 15:09 ` [PATCH 18/18] doc: update mlx5 guide on tunnel offloading Xueming Li

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=20180423121635.32347-4-xuemingl@mellanox.com \
    --to=xuemingl@mellanox.com \
    --cc=adrien.mazarguil@6wind.com \
    --cc=dev@dpdk.org \
    --cc=jingjing.wu@intel.com \
    --cc=nelio.laranjeiro@6wind.com \
    --cc=olivier.matz@6wind.com \
    --cc=shahafs@mellanox.com \
    --cc=thomas@monjalon.net \
    --cc=wenzhuo.lu@intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.