Acked-by: Eli Britstein <el...@nvidia.com>

>-----Original Message-----
>From: Simon Horman <simon.hor...@corigine.com>
>Sent: Wednesday, 9 November 2022 21:55
>To: d...@openvswitch.org
>Cc: Eelco Chaudron <echau...@redhat.com>; Ilya Maximets
><i.maxim...@ovn.org>; Eli Britstein <el...@nvidia.com>; Chaoyong He
><chaoyong...@corigine.com>; oss-driv...@corigine.com; Louis Peens
><louis.pe...@corigine.com>; Simon Horman <simon.hor...@corigine.com>
>Subject: [PATCH v4] netdev-offload-dpdk: Enhance the support of tunnel pop
>action
>
>External email: Use caution opening links or attachments
>
>
>From: Chaoyong He <chaoyong...@corigine.com>
>
>Populate the 'is_ipv6' field of 'struct rte_flow_tunnel', which can be used in
>the implementation of tunnel pop action for DPDK PMD.
>
>Fixes: be56e063d028 ("netdev-offload-dpdk: Support tunnel pop action.")
>Signed-off-by: Chaoyong He <chaoyong...@corigine.com>
>Reviewed-by: Louis Peens <louis.pe...@corigine.com>
>Signed-off-by: Simon Horman <simon.hor...@corigine.com>
>---
> lib/netdev-offload-dpdk.c | 14 ++++++++++----
> 1 file changed, 10 insertions(+), 4 deletions(-)
>
>v4
>* Reworked changelog
>* Dropped other patches from patchset
>
>v3
>* Add fixes tag
>
>v2
>* No change
>
>diff --git a/lib/netdev-offload-dpdk.c b/lib/netdev-offload-dpdk.c index
>80a64a6cc06a..38f00fd309e6 100644
>--- a/lib/netdev-offload-dpdk.c
>+++ b/lib/netdev-offload-dpdk.c
>@@ -1099,12 +1099,18 @@ vport_to_rte_tunnel(struct netdev *vport,
>     const struct netdev_tunnel_config *tnl_cfg;
>
>     memset(tunnel, 0, sizeof *tunnel);
>+
>+    tnl_cfg = netdev_get_tunnel_config(vport);
>+    if (!tnl_cfg) {
>+        return -1;
>+    }
>+
>+    if (!IN6_IS_ADDR_V4MAPPED(&tnl_cfg->ipv6_dst)) {
>+        tunnel->is_ipv6 = true;
>+    }
>+
>     if (!strcmp(netdev_get_type(vport), "vxlan")) {
>         tunnel->type = RTE_FLOW_ITEM_TYPE_VXLAN;
>-        tnl_cfg = netdev_get_tunnel_config(vport);
>-        if (!tnl_cfg) {
>-            return -1;
>-        }
>         tunnel->tp_dst = tnl_cfg->dst_port;
>         if (!VLOG_DROP_DBG(&rl)) {
>             ds_put_format(s_tnl, "flow tunnel create %d type vxlan; ",
>--
>2.30.2

_______________________________________________
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to