Skip to contentSkip to conversation

mlx5-next updates 2026-04-03

PATCH Applied Tariq Toukan 2 participants 4 messages Apr 3 – Apr 9

Subsystems (5)
lore
Share & tools
lore

Tariq Toukan

author maintainer
#0 lore raw

cover mlx5-next updates 2026-04-03

Hi,

This series contains mlx5 shared updates as preparation for upcoming features.

Regards,
Tariq

Moshe Shemesh (2):
net/mlx5: Rename MLX5_PF page counter type to MLX5_SELF net/mlx5: Add icm_mng_function_id_mode cap bit

 drivers/net/ethernet/mellanox/mlx5/core/pagealloc.c | 3 ++-
 include/linux/mlx5/driver.h                         | 2 +-
 include/linux/mlx5/mlx5_ifc.h                       | 8 +++++++-
 3 files changed, 10 insertions(+), 3 deletions(-)

base-commit: 26469110c750c8179560637dd813e5d65b8148d2

Signature · 1 line
2.44.0
author maintainer
#1 lore raw

PATCH 1/2 net/mlx5: Rename MLX5_PF page counter type to MLX5_SELF

From: Moshe Shemesh <[email protected]>

The MLX5_PF enum value in mlx5_func_type is used to track firmware page allocations for the page manager function itself, which is either the ECPF on SmartNIC systems or the host PF when there is no ECPF.

Rename it to MLX5_SELF to accurately reflect that this counter tracks pages allocated by the manager for its own use, regardless of whether it is a PF or ECPF.

---
 drivers/net/ethernet/mellanox/mlx5/core/pagealloc.c | 3 ++-
 include/linux/mlx5/driver.h                         | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)
drivers/net/ethernet/mellanox/mlx5/core/pagealloc.c +2 -1
index 5ccb3ce98acb..77ffa31cc505 100644
@@ -77,7 +77,8 @@ static u32 get_function(u16 func_id, bool ec_function)
 static u16 func_id_to_type(struct mlx5_core_dev *dev, u16 func_id, bool ec_function)
 {
 	if (!func_id)
-		return mlx5_core_is_ecpf(dev) && !ec_function ? MLX5_HOST_PF : MLX5_PF;
+		return mlx5_core_is_ecpf(dev) && !ec_function ?
+			MLX5_HOST_PF : MLX5_SELF;
 
 	if (func_id <= max(mlx5_core_max_vfs(dev), mlx5_core_max_ec_vfs(dev))) {
 		if (ec_function)
include/linux/mlx5/driver.h +1 -1
index b8b5af78284d..10bc913591d5 100644
@@ -550,7 +550,7 @@ struct mlx5_debugfs_entries {
 };
 
 enum mlx5_func_type {
-	MLX5_PF,
+	MLX5_SELF,
 	MLX5_VF,
 	MLX5_SF,
 	MLX5_HOST_PF,
Signature · 1 line
2.44.0
author maintainer
#2 lore raw

PATCH 2/2 net/mlx5: Add icm_mng_function_id_mode cap bit

In reply to Tariq Toukan

From: Moshe Shemesh <[email protected]>

Introduce the capability bit icm_mng_function_id_mode to indicate that the device firmware uses vhca_id instead of function_id as the effective identifier for the firmware commands MANAGE_PAGES, QUERY_PAGES, and page request event.

---
 include/linux/mlx5/mlx5_ifc.h | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
include/linux/mlx5/mlx5_ifc.h +7 -1
index 2400b4c38c77..007f5138db2b 100644
@@ -1654,6 +1654,11 @@ enum {
 	MLX5_STEERING_FORMAT_CONNECTX_8   = 3,
 };
 
+enum {
+	MLX5_ID_MODE_FUNCTION_INDEX   = 0,
+	MLX5_ID_MODE_FUNCTION_VHCA_ID = 1,
+};
+
 struct mlx5_ifc_cmd_hca_cap_bits {
 	u8         reserved_at_0[0x6];
 	u8         page_request_disable[0x1];
@@ -1916,7 +1921,8 @@ struct mlx5_ifc_cmd_hca_cap_bits {
 	u8         reserved_at_280[0x10];
 	u8         max_wqe_sz_sq[0x10];
 
-	u8         reserved_at_2a0[0x7];
+	u8         icm_mng_function_id_mode[0x1];
+	u8         reserved_at_2a1[0x6];
 	u8         mkey_pcie_tph[0x1];
 	u8         reserved_at_2a8[0x1];
 	u8         tis_tir_td_order[0x1];
Signature · 1 line
2.44.0
#3 lore raw
In reply to Tariq Toukan
Quoted 11 lines · Tariq Toukan

This series contains mlx5 shared updates as preparation for upcoming features.

Regards,
Tariq

Moshe Shemesh (2):
net/mlx5: Rename MLX5_PF page counter type to MLX5_SELF net/mlx5: Add icm_mng_function_id_mode cap bit

[...]

Applied, thanks!

[1/2] net/mlx5: Rename MLX5_PF page counter type to MLX5_SELF

      https://git.kernel.org/rdma/rdma/c/f9e3bd43d55f24
[2/2] net/mlx5: Add icm_mng_function_id_mode cap bit
      https://git.kernel.org/rdma/rdma/c/a1bac8b70ede33

Best regards,

Signature · 1 line
Leon Romanovsky <[email protected]>