]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5e: Refactor reg_c1 usage
authorVlad Buslov <vladbu@nvidia.com>
Mon, 31 Aug 2020 13:18:19 +0000 (16:18 +0300)
committerSaeed Mahameed <saeedm@nvidia.com>
Sat, 6 Feb 2021 04:53:37 +0000 (20:53 -0800)
commit51c1637eac14205639d673f342361ac95e11c538
tree891f6a7f9954b5478bd0b99b081755268efc1aad
parent43ca982d871f6820c59cdd4b52989a2e81225995
net/mlx5e: Refactor reg_c1 usage

Following patch in series uses reg_c1 in eswitch code. To use reg_c1
helpers in both TC and eswitch code, refactor existing helpers according to
similar use case of reg_c0 and move the functionality into eswitch.h.
Calculate reg mappings length from new defines to ensure that they are
always in sync and only need to be changed in single place.

Signed-off-by: Vlad Buslov <vladbu@nvidia.com>
Signed-off-by: Dmytro Linkin <dlinkin@nvidia.com>
Reviewed-by: Roi Dayan <roid@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
drivers/net/ethernet/mellanox/mlx5/core/en/rep/tc.c
drivers/net/ethernet/mellanox/mlx5/core/en/tc_ct.h
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c
drivers/net/ethernet/mellanox/mlx5/core/en_tc.h
include/linux/mlx5/eswitch.h