net/mlx5: fix MPLS tunnel outer layer overwrite
authorDariusz Sosnowski <dsosnowski@nvidia.com>
Wed, 17 Nov 2021 09:59:33 +0000 (11:59 +0200)
committerRaslan Darawsheh <rasland@nvidia.com>
Wed, 17 Nov 2021 10:48:18 +0000 (11:48 +0100)
commit421177ccd7f59ec8d898fd6aa6bc6fb9eb298a52
treef4adebee225e96abd08c2ccd6171e6a39a2de6df
parent7775172c045f3387cee47d3f32633255d37ba785
net/mlx5: fix MPLS tunnel outer layer overwrite

mlx5 PMD incorrectly overwrote outer layer fields in MPLS tunnel
rte_flow patterns using defaults for MPLS tunnels. This included
overwriting UDP destination port in MPLSoUDP and GRE protocol field in
MPLSoGRE.

This patch fixes this behavior. If application provides the values in
flow pattern items preceding the MPLS flow item the provided values will
be used, otherwise the defaults will be applied.

Fixes: d1abe664ddde ("net/mlx5: add MPLS to Direct Verbs flow engine")
Cc: stable@dpdk.org
Signed-off-by: Dariusz Sosnowski <dsosnowski@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
drivers/net/mlx5/mlx5_flow_dv.c