aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mlx5/vport.h
diff options
context:
space:
mode:
authorParav Pandit <parav@mellanox.com>2019-05-15 00:04:27 -0500
committerSaeed Mahameed <saeedm@mellanox.com>2019-07-03 12:50:42 -0700
commit2752b823169b216db142c4466b43269281962dcf (patch)
tree6c01796b4436773d85fec714f879cc301a66bb79 /include/linux/mlx5/vport.h
parentnet/mlx5: Expose device definitions for object events (diff)
downloadlinux-dev-2752b823169b216db142c4466b43269281962dcf.tar.xz
linux-dev-2752b823169b216db142c4466b43269281962dcf.zip
net/mlx5: Introduce and use mlx5_eswitch_get_total_vports()
Instead MLX5_TOTAL_VPORTS, use mlx5_eswitch_get_total_vports(). mlx5_eswitch_get_total_vports() in subsequent patch accounts for SF vports as well. Expanding MLX5_TOTAL_VPORTS macro would require exposing SF internals to more generic vport.h header file. Such exposure is not desired. Hence a mlx5_eswitch_get_total_vports() is introduced. Given that mlx5_eswitch_get_total_vports() API wants to work on const mlx5_core_dev*, change its helper functions also to accept const *dev. Signed-off-by: Parav Pandit <parav@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Diffstat (limited to '')
-rw-r--r--include/linux/mlx5/vport.h3
1 files changed, 0 insertions, 3 deletions
diff --git a/include/linux/mlx5/vport.h b/include/linux/mlx5/vport.h
index 6cbf29229749..16060fb9b5e5 100644
--- a/include/linux/mlx5/vport.h
+++ b/include/linux/mlx5/vport.h
@@ -44,9 +44,6 @@
MLX5_VPORT_UPLINK_PLACEHOLDER + \
MLX5_VPORT_ECPF_PLACEHOLDER(mdev))
-#define MLX5_TOTAL_VPORTS(mdev) (MLX5_SPECIAL_VPORTS(mdev) + \
- mlx5_core_max_vfs(mdev))
-
#define MLX5_VPORT_MANAGER(mdev) \
(MLX5_CAP_GEN(mdev, vport_group_manager) && \
(MLX5_CAP_GEN(mdev, port_type) == MLX5_CAP_PORT_TYPE_ETH) && \