net/mlx5: fix tunnel offload object allocation
authorGregory Etelson <getelson@nvidia.com>
Mon, 16 Nov 2020 14:02:21 +0000 (16:02 +0200)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 20 Nov 2020 20:10:04 +0000 (21:10 +0100)
commit9cac7ded37479ec59ca2f52c043a5e4326c24a22
tree96890b8b29e32bb2d48f69d18474171496b1b3d0
parenteab3ca48580c1599da754c621c1a941be27d3e9c
net/mlx5: fix tunnel offload object allocation

The original patch allocated tunnel offload objects with invalid
indexes. As the result, PMD tunnel object allocation failed.

In this patch indexed pool provides both an index and memory for a new
tunnel offload object.
Also tunnel offload ipool moved to dv enabled code only.

Fixes: 4ae8825c5085 ("net/mlx5: use indexed pool as id generator")

Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
drivers/net/mlx5/mlx5.c
drivers/net/mlx5/mlx5.h
drivers/net/mlx5/mlx5_flow.c