net/mlx5: fix meter policy ID table container
authorShun Hao <shunh@nvidia.com>
Fri, 2 Jul 2021 09:14:44 +0000 (12:14 +0300)
committerRaslan Darawsheh <rasland@nvidia.com>
Thu, 8 Jul 2021 20:09:25 +0000 (22:09 +0200)
commitefcce4dcdc7e4e16bb139b388c1855d937996a16
tree11981c087d6704c93b3f54555f05f6d9c39ce8c2
parenta295c69a8b24f34f9d98959853265b31bcbcc133
net/mlx5: fix meter policy ID table container

The meter policy handlers are managed by user IDs and the driver used l3
table in order to map the user ID to the internal driver handler of the
policy.

The l3 table was wrongly saved in the shared device structure which
manages all the switch domain ports what made the user IDs shared
between different ethdev ports.

Move the policy l3 table to be per port by saving it in the port private
structure.

Fixes: afb4aa4f122 ("net/mlx5: support meter policy operations")
Cc: stable@dpdk.org
Signed-off-by: Shun Hao <shunh@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
drivers/net/mlx5/mlx5.c
drivers/net/mlx5/mlx5.h
drivers/net/mlx5/mlx5_flow_meter.c