net/mlx5e: Convert TIR to a dedicated object
authorMaxim Mikityanskiy <maximmi@nvidia.com>
Tue, 6 Apr 2021 17:33:40 +0000 (20:33 +0300)
committerSaeed Mahameed <saeedm@nvidia.com>
Mon, 26 Jul 2021 16:50:40 +0000 (09:50 -0700)
commita6696735d694b365bca45873e9dbca26120a8375
tree778a68df3c3c488dba466d07086fb1c21f5b4980
parent6fe5ff2c77805f1a3a4abf226087bf9ce1299371
net/mlx5e: Convert TIR to a dedicated object

Code related to TIR is now encapsulated into a dedicated object and put
into new files en/tir.{c,h}. All usages are converted.

The Builder pattern is used to initialize a TIR. It allows to create a
multitude of different configurations, turning on and off some specific
features in different combinations, without having long parameter lists,
initializers per usage and repeating code in initializers.

Signed-off-by: Maxim Mikityanskiy <maximmi@nvidia.com>
Reviewed-by: Maor Dickman <maord@nvidia.com>
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
drivers/net/ethernet/mellanox/mlx5/core/Makefile
drivers/net/ethernet/mellanox/mlx5/core/en.h
drivers/net/ethernet/mellanox/mlx5/core/en/rx_res.h
drivers/net/ethernet/mellanox/mlx5/core/en/tir.c [new file with mode: 0644]
drivers/net/ethernet/mellanox/mlx5/core/en/tir.h [new file with mode: 0644]
drivers/net/ethernet/mellanox/mlx5/core/en/trap.c
drivers/net/ethernet/mellanox/mlx5/core/en_common.c
drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c
drivers/net/ethernet/mellanox/mlx5/core/en_fs_ethtool.c
drivers/net/ethernet/mellanox/mlx5/core/en_main.c
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c