DPDK patches and discussions
 help / color / mirror / Atom feed
From: Adrien Mazarguil <adrien.mazarguil@6wind.com>
To: Shahaf Shuler <shahafs@mellanox.com>,
	Yongseok Koh <yskoh@mellanox.com>,
	Slava Ovsiienko <viacheslavo@mellanox.com>
Cc: dev@dpdk.org
Subject: [dpdk-dev] [PATCH 0/8] net/mlx5: add switch offload for VXLAN encap/decap
Date: Fri, 31 Aug 2018 11:57:25 +0200	[thread overview]
Message-ID: <20180831092038.23051-1-adrien.mazarguil@6wind.com> (raw)

This series adds support for RTE_FLOW_ACTION_TYPE_VXLAN_ENCAP and
RTE_FLOW_ACTION_TYPE_VXLAN_DECAP to mlx5.

Since these actions are supported at the switch level, the "transfer"
attribute must be set on such flow rules. They must also be combined with a
port redirection action to make sense.

A typical use case is port representors in switchdev mode, with VXLAN
traffic encapsulation performed on traffic coming *from* a representor and
decapsulation on traffic going *to* that representor, in order to
transparently assign a given VXLAN to VF traffic.

Since only ingress is supported, encapsulation flow rules are normally
applied on a physical port and emit traffic to a port representor. The
opposite order is used for decapsulation.

Like other mlx5 switch flow rule actions, these are implemented through
Linux's TC flower API. Since the Linux interface for VXLAN encap/decap
involves virtual network devices (i.e. ip link add type vxlan [...]), the
PMD automatically spawns them on a needed basis through Netlink calls. The
added complexity necessarily results in a rather convoluted PMD
implementation.

This series relies on "ethdev: add flow API object converter" [1] which
should applied first since testpmd does not provide a means to test VXLAN
encap otherwise.

[1] https://patches.dpdk.org/project/dpdk/list/?series=1123

Adrien Mazarguil (8):
  net/mlx5: speed up interface index retrieval for flow rules
  net/mlx5: clean up redundant interface name getters
  net/mlx5: rename internal function
  net/mlx5: enhance TC flow rule send/ack function
  net/mlx5: prepare switch flow rule parser for encap offloads
  net/mlx5: add convenience macros to switch flow rule engine
  net/mlx5: add VXLAN encap support to switch flow rules
  net/mlx5: add VXLAN decap support to switch flow rules

 drivers/net/mlx5/Makefile       |   75 ++
 drivers/net/mlx5/mlx5.c         |   74 +-
 drivers/net/mlx5/mlx5.h         |   28 +-
 drivers/net/mlx5/mlx5_ethdev.c  |  188 ++--
 drivers/net/mlx5/mlx5_flow.c    |   16 +-
 drivers/net/mlx5/mlx5_nl.c      |    9 +-
 drivers/net/mlx5/mlx5_nl_flow.c | 1763 ++++++++++++++++++++++++++++++++--
 7 files changed, 1871 insertions(+), 282 deletions(-)

-- 
2.11.0

             reply	other threads:[~2018-08-31  9:57 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-31  9:57 Adrien Mazarguil [this message]
2018-08-31  9:57 ` [dpdk-dev] [PATCH 1/8] net/mlx5: speed up interface index retrieval for flow rules Adrien Mazarguil
2018-08-31  9:57 ` [dpdk-dev] [PATCH 2/8] net/mlx5: clean up redundant interface name getters Adrien Mazarguil
2018-08-31  9:57 ` [dpdk-dev] [PATCH 3/8] net/mlx5: rename internal function Adrien Mazarguil
2018-08-31  9:57 ` [dpdk-dev] [PATCH 4/8] net/mlx5: enhance TC flow rule send/ack function Adrien Mazarguil
2018-08-31  9:57 ` [dpdk-dev] [PATCH 5/8] net/mlx5: prepare switch flow rule parser for encap offloads Adrien Mazarguil
2018-08-31  9:57 ` [dpdk-dev] [PATCH 6/8] net/mlx5: add convenience macros to switch flow rule engine Adrien Mazarguil
2018-08-31  9:57 ` [dpdk-dev] [PATCH 7/8] net/mlx5: add VXLAN encap support to switch flow rules Adrien Mazarguil
2018-08-31  9:57 ` [dpdk-dev] [PATCH 8/8] net/mlx5: add VXLAN decap " Adrien Mazarguil

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=20180831092038.23051-1-adrien.mazarguil@6wind.com \
    --to=adrien.mazarguil@6wind.com \
    --cc=dev@dpdk.org \
    --cc=shahafs@mellanox.com \
    --cc=viacheslavo@mellanox.com \
    --cc=yskoh@mellanox.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).