]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: E-Switch, Initialize eswitch acls ns when eswitch is enabled
authorParav Pandit <parav@nvidia.com>
Mon, 1 Mar 2021 12:12:13 +0000 (14:12 +0200)
committerSaeed Mahameed <saeedm@nvidia.com>
Wed, 14 Apr 2021 18:02:43 +0000 (11:02 -0700)
commitb0fe51251b3c790cdcfed627083abd5f4c52d4d4
treefc38e982601f9d86fa837336b8af0cd309e53132
parente237f7c675417128c1c019044be0f9583b2b8c0d
net/mlx5: E-Switch, Initialize eswitch acls ns when eswitch is enabled

Currently eswitch flow steering (FS) namespace of vport's ingress and
egress ACL are enabled when FS layer is initialized. This is done even
when eswitch is diabled. This demands that total eswitch ports to be
known to FS layer without eswitch in use.

Given the FS core is not dependent on eswitch, make namespace init and
cleanup routines as helper routines to be invoked only when eswitch is
needed.

With this change, ingress and egress ACL namespaces are created only
when eswitch legacy/offloads mode is enabled.

Signed-off-by: Parav Pandit <parav@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
drivers/net/ethernet/mellanox/mlx5/core/eswitch.c
drivers/net/ethernet/mellanox/mlx5/core/fs_core.c
drivers/net/ethernet/mellanox/mlx5/core/fs_core.h