RE: [PATCH net-next 2/2] net/mlx5: implement max_sfs parameter
From: Loktionov, Aleksandr
Date: Mon May 18 2026 - 05:13:41 EST
> -----Original Message-----
> From: Tariq Toukan <tariqt@xxxxxxxxxx>
> Sent: Sunday, May 17, 2026 1:27 PM
> To: Eric Dumazet <edumazet@xxxxxxxxxx>; Jakub Kicinski
> <kuba@xxxxxxxxxx>; Paolo Abeni <pabeni@xxxxxxxxxx>; Andrew Lunn
> <andrew+netdev@xxxxxxx>; David S. Miller <davem@xxxxxxxxxxxxx>
> Cc: Jiri Pirko <jiri@xxxxxxxxxxx>; Simon Horman <horms@xxxxxxxxxx>;
> Jonathan Corbet <corbet@xxxxxxx>; Shuah Khan
> <skhan@xxxxxxxxxxxxxxxxxxx>; Saeed Mahameed <saeedm@xxxxxxxxxx>; Leon
> Romanovsky <leon@xxxxxxxxxx>; Tariq Toukan <tariqt@xxxxxxxxxx>; Mark
> Bloch <mbloch@xxxxxxxxxx>; Vlad Dumitrescu <vdumitrescu@xxxxxxxxxx>;
> Loktionov, Aleksandr <aleksandr.loktionov@xxxxxxxxx>; Daniel Zahka
> <daniel.zahka@xxxxxxxxx>; David Ahern <dsahern@xxxxxxxxxx>; Nikolay
> Aleksandrov <razor@xxxxxxxxxxxxx>; netdev@xxxxxxxxxxxxxxx; linux-
> doc@xxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx; linux-
> rdma@xxxxxxxxxxxxxxx; Gal Pressman <gal@xxxxxxxxxx>; Dragos Tatulea
> <dtatulea@xxxxxxxxxx>; Jiri Pirko <jiri@xxxxxxxxxx>; Nikolay
> Aleksandrov <nikolay@xxxxxxxxxx>
> Subject: [PATCH net-next 2/2] net/mlx5: implement max_sfs parameter
>
> From: Nikolay Aleksandrov <nikolay@xxxxxxxxxx>
>
> Implement max_sfs generic parameter to allow users to control the
> total light-weight NIC subfunctions that can be created using devlink
> instead of external vendor tools. A value of 0 will effectively
> disable creation of new subfunction devices. A warning is sent to
> user-space via extack (returning extack without error code is
> interpreted as a warning by user-space tools).
>
> Signed-off-by: Nikolay Aleksandrov <nikolay@xxxxxxxxxx>
> Reviewed-by: David Ahern <dsahern@xxxxxxxxxx>
> Signed-off-by: Tariq Toukan <tariqt@xxxxxxxxxx>
> ---
> Documentation/networking/devlink/mlx5.rst | 7 +-
> .../mellanox/mlx5/core/lib/nv_param.c | 83
> ++++++++++++++++++-
> 2 files changed, 86 insertions(+), 4 deletions(-)
>
> diff --git a/Documentation/networking/devlink/mlx5.rst
> b/Documentation/networking/devlink/mlx5.rst
> index 4bba4d780a4a..283b93d16861 100644
> --- a/Documentation/networking/devlink/mlx5.rst
> +++ b/Documentation/networking/devlink/mlx5.rst
> @@ -45,8 +45,13 @@ Parameters
> - The range is between 1 and a device-specific max.
> - Applies to each physical function (PF) independently, if the
> device
> supports it. Otherwise, it applies symmetrically to all PFs.
> + * - ``max_sfs``
> + - permanent
> + - The range is between 0 and a device-specific max.
> + - Applies to each physical function (PF) independently.
>
> -Note: permanent parameters such as ``enable_sriov`` and ``total_vfs``
> require FW reset to take effect
> +Note: permanent parameters such as ``enable_sriov``, ``total_vfs` and
> ``max_sfs``
I think one ` is missed after the ``total_vfs` ?
...
>
> DEVLINK_PARAM_DRIVER(MLX5_DEVLINK_PARAM_ID_CQE_COMPRESSION_TYPE
> ,
> "cqe_compress_type",
> DEVLINK_PARAM_TYPE_STRING,
> BIT(DEVLINK_PARAM_CMODE_PERMANENT),
> --
> 2.44.0