Re: [PATCH net-next 2/2] net/mlx5: implement max_sfs parameter

From
Nikolay Aleksandrov <hidden>
Date
2026-05-18 10:37:41
Also in
linux-doc, linux-rdma, lkml
Reply to
Loktionov, Aleksandr, 2026-05-18
On Mon, May 18, 2026 at 09:05:52AM +0000, Loktionov, Aleksandr wrote:
quoted
-----Original Message-----
From: Tariq Toukan <tariqt@nvidia.com>
Sent: Sunday, May 17, 2026 1:27 PM
To: Eric Dumazet <redacted>; Jakub Kicinski
[off-list ref]; Paolo Abeni [off-list ref]; Andrew Lunn
[off-list ref]; David S. Miller [off-list ref]
Cc: Jiri Pirko <jiri@resnulli.us>; Simon Horman <horms@kernel.org>;
Jonathan Corbet [off-list ref]; Shuah Khan
[off-list ref]; Saeed Mahameed [off-list ref]; Leon
Romanovsky [off-list ref]; Tariq Toukan [off-list ref]; Mark
Bloch [off-list ref]; Vlad Dumitrescu [off-list ref];
Loktionov, Aleksandr [off-list ref]; Daniel Zahka
[off-list ref]; David Ahern [off-list ref]; Nikolay
Aleksandrov [off-list ref]; netdev@vger.kernel.org; linux-
doc@vger.kernel.org; linux-kernel@vger.kernel.org; linux-
rdma@vger.kernel.org; Gal Pressman [off-list ref]; Dragos Tatulea
[off-list ref]; Jiri Pirko [off-list ref]; Nikolay
Aleksandrov [off-list ref]
Subject: [PATCH net-next 2/2] net/mlx5: implement max_sfs parameter

From: Nikolay Aleksandrov <redacted>

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 <redacted>
Reviewed-by: David Ahern <dsahern@kernel.org>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
---
 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` ?


...
ha, good catch! there's a missing ` indeed :)
quoted
	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
Thread (6 messages) 6 messages, 3 authors, last reply 2026-05-18
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help