summaryrefslogtreecommitdiff
path: root/include/linux/mlx5
diff options
context:
space:
mode:
authorDaniel Jurgens <danielj@nvidia.com>2023-03-07 20:36:14 +0300
committerSaeed Mahameed <saeedm@nvidia.com>2023-06-10 04:40:51 +0300
commitdc13180824b78e1e4e7ae1ce22160ae8e5fb858e (patch)
treef97b403ba6d6cf12d0118c641e766f95e66bb36d /include/linux/mlx5
parent93b36d0f2892357906f1058778c9188ff857baa1 (diff)
downloadlinux-dc13180824b78e1e4e7ae1ce22160ae8e5fb858e.tar.xz
net/mlx5: Enable devlink port for embedded cpu VF vports
Enable creation of a devlink port for EC VF vports. Signed-off-by: Daniel Jurgens <danielj@nvidia.com> Reviewed-by: William Tu <witu@nvidia.com> Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Diffstat (limited to 'include/linux/mlx5')
-rw-r--r--include/linux/mlx5/driver.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/mlx5/driver.h b/include/linux/mlx5/driver.h
index 9a744c48eec2..252b6a6965b8 100644
--- a/include/linux/mlx5/driver.h
+++ b/include/linux/mlx5/driver.h
@@ -474,6 +474,7 @@ struct mlx5_core_sriov {
struct mlx5_vf_context *vfs_ctx;
int num_vfs;
u16 max_vfs;
+ u16 max_ec_vfs;
};
struct mlx5_fc_pool {
@@ -1244,6 +1245,11 @@ static inline u16 mlx5_core_max_vfs(const struct mlx5_core_dev *dev)
return dev->priv.sriov.max_vfs;
}
+static inline u16 mlx5_core_max_ec_vfs(const struct mlx5_core_dev *dev)
+{
+ return dev->priv.sriov.max_ec_vfs;
+}
+
static inline int mlx5_get_gid_table_len(u16 param)
{
if (param > 4) {