net/mlx5: add flow table tunnel offload attribute
authorSuanming Mou <suanmingm@nvidia.com>
Wed, 28 Oct 2020 09:33:32 +0000 (17:33 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 3 Nov 2020 22:35:04 +0000 (23:35 +0100)
commiteeca57902713fd5b89290c645808faf8c4f74b5b
tree712195fb3cf361725ec3b359172453e46460218a
parente69a59227db0f2dd6ccc9f618d0ff7e6f0dd03aa
net/mlx5: add flow table tunnel offload attribute

As flow table is shared between the ports in the same shared IB device,
flow table may be created by one port and released by other port.

Currently, the tunnel offloading active check in flow table release is
based on the port which release the flow table. Since the flow table
create port and release port may have different tunnel offloading
configuration, it will cause invalid tunnel offloading release or
tunnel offloading resource leaks.

Add the flow table tunnel offloading attribute to indicate the flow
table has tunnel offloading resource or not to avoid wrong tunnel
offloading operation.

Signed-off-by: Suanming Mou <suanmingm@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
drivers/net/mlx5/mlx5_flow.h
drivers/net/mlx5/mlx5_flow_dv.c