OSDN Git Service

net/mlx5: E-Switch, Alloc and free unique metadata for match
authorVu Pham <vuhuong@mellanox.com>
Sat, 29 Feb 2020 00:10:34 +0000 (16:10 -0800)
committerSaeed Mahameed <saeedm@mellanox.com>
Thu, 28 May 2020 01:13:49 +0000 (18:13 -0700)
commit133dcfc577eaec6538db4ebd8b9205b361f59018
tree3618f02cd9da645a0feee85871039e1668ac1684
parentd97555e1452943264295cd3c1f066474bc3660dd
net/mlx5: E-Switch, Alloc and free unique metadata for match

Introduce infrastructure to create unique metadata for match
for vport without depending on vport_num. Vport uses its
default metadata for match in standalone configuration but
will share a different unique "bond_metadata" for match with
other vports in bond configuration.

Using ida to generate unique metadata for match for vports
in default and bond configurations.

Introduce APIs to generate, free metadata for match.
Introduce APIs to set vport's bond_metadata and replace its
ingress acl rules with bond_metatada.

Signed-off-by: Vu Pham <vuhuong@mellanox.com>
Reviewed-by: Parav Pandit <parav@mellanox.com>
Reviewed-by: Roi Dayan <roid@mellanox.com>
Reviewed-by: Mark Bloch <markb@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/esw/acl/ingress_ofld.c
drivers/net/ethernet/mellanox/mlx5/core/esw/acl/ofld.h
drivers/net/ethernet/mellanox/mlx5/core/eswitch.c
drivers/net/ethernet/mellanox/mlx5/core/eswitch.h
drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c