mlx5-next updates 2026-07-13
Subsystems (5)
Tariq Toukan
maintainercover mlx5-next updates 2026-07-13
Hi,
This series contains mlx5 shared updates.
Regards,
Tariq
Cosmin Ratiu (1):
net/mlx5: ifc: Add PSP related fields
Shay Drory (1):
net/mlx5: Drop redundant esw_cap, reuse e_switch_cap
.../net/ethernet/mellanox/mlx5/core/fs_core.h | 12 +----- .../mellanox/mlx5/core/steering/hws/cmd.c | 6 +-- include/linux/mlx5/device.h | 1 + include/linux/mlx5/mlx5_ifc.h | 38 ++++++++++--------- 4 files changed, 25 insertions(+), 32 deletions(-)
base-commit: ddbddbf8aee54bee038149187270c93a45478473
Signature · 1 line
2.44.0
Tariq Toukan
maintainerPATCH 1/2 net/mlx5: Drop redundant esw_cap, reuse e_switch_cap
From: Shay Drory <[email protected]>
esw_manager_vport_number{,_valid} and merged_eswitch were read through a separate mlx5_ifc_esw_cap_bits struct, but these bits live in the e-switch capability that mlx5_ifc_e_switch_cap_bits already describes (both overlay the same QUERY_HCA_CAP op_mod 0x9 output).
Add esw_manager_vport_number{,_valid} to mlx5_ifc_e_switch_cap_bits at the same offsets, drop the redundant mlx5_ifc_esw_cap_bits and its hca_cap_union member, and switch the only user (hws/cmd.c) to capability.e_switch_cap.
--- .../mellanox/mlx5/core/steering/hws/cmd.c | 6 +++--- include/linux/mlx5/mlx5_ifc.h | 21 +++++-------------- 2 files changed, 8 insertions(+), 19 deletions(-)
drivers/net/ethernet/mellanox/mlx5/core/steering/hws/cmd.c +3 -3
@@ -1172,13 +1172,13 @@ int mlx5hws_cmd_query_caps(struct mlx5_core_dev *mdev, }if (MLX5_GET (query_hca_cap_out, out, - capability.esw_cap.esw_manager_vport_number_valid)) + capability.e_switch_cap.esw_manager_vport_number_valid)) caps->eswitch_manager_vport_number =MLX5_GET (query_hca_cap_out, out, - capability.esw_cap.esw_manager_vport_number); + capability.e_switch_cap.esw_manager_vport_number); caps->merged_eswitch =MLX5_GET (query_hca_cap_out, out, - capability.esw_cap.merged_eswitch); + capability.e_switch_cap.merged_eswitch); } ret =mlx5_cmd_exec (mdev, in,sizeof (in), out, out_size);
include/linux/mlx5/mlx5_ifc.h +5 -16
@@ -1042,20 +1042,6 @@ struct mlx5_ifc_wqe_based_flow_table_cap_bits {u8 reserved_at_1c1[0x1f ]; }; -struct mlx5_ifc_esw_cap_bits { -u8 reserved_at_0[0x1d ]; -u8 merged_eswitch[0x1 ]; -u8 reserved_at_1e[0x2 ]; - -u8 reserved_at_20[0x40 ]; - -u8 esw_manager_vport_number_valid[0x1 ]; -u8 reserved_at_61[0xf ]; -u8 esw_manager_vport_number[0x10 ]; - -u8 reserved_at_80[0x780 ]; -}; -enum {MLX5_COUNTER_SOURCE_ESWITCH =0x0 ,MLX5_COUNTER_FLOW_ESWITCH =0x1 ,
@@ -1096,7 +1082,11 @@ struct mlx5_ifc_e_switch_cap_bits {u8 log_max_esw_sf[0x5 ];u8 esw_sf_base_id[0x10 ]; -u8 reserved_at_60[0x7a0 ]; +u8 esw_manager_vport_number_valid[0x1 ]; +u8 reserved_at_61[0xf ]; +u8 esw_manager_vport_number[0x10 ]; + +u8 reserved_at_80[0x780 ]; };
@@ -3855,7 +3845,6 @@ union mlx5_ifc_hca_cap_union_bits {struct mlx5_ifc_flow_table_nic_cap_bits flow_table_nic_cap;struct mlx5_ifc_flow_table_eswitch_cap_bits flow_table_eswitch_cap;struct mlx5_ifc_wqe_based_flow_table_cap_bits wqe_based_flow_table_cap; -struct mlx5_ifc_esw_cap_bits esw_cap;struct mlx5_ifc_e_switch_cap_bits e_switch_cap;struct mlx5_ifc_port_selection_cap_bits port_selection_cap;struct mlx5_ifc_qos_cap_bits qos_cap;
Signature · 1 line
2.44.0
Tariq Toukan
maintainerPATCH 2/2 net/mlx5: ifc: Add PSP related fields
In reply to Tariq ToukanFrom: Cosmin Ratiu <[email protected]>
This adds:
- misc_parameters_6, containing a few fields for matching PSP headers. As this is the last misc_parameters field defined, retire the old optimization added in commit [1] to not touch the reserved part.
- PSP decap action.
- PSP SPI header field pointer.
[1] commit 667cb65ae5ad ("net/mlx5: Don't store reserved part in FTEs and FGs")
--- .../net/ethernet/mellanox/mlx5/core/fs_core.h | 12 +----------- include/linux/mlx5/device.h | 1 + include/linux/mlx5/mlx5_ifc.h | 17 +++++++++++++++-- 3 files changed, 17 insertions(+), 13 deletions(-)
drivers/net/ethernet/mellanox/mlx5/core/fs_core.h +1 -11
@@ -214,17 +214,7 @@ struct mlx5_ft_underlay_qp {u32 qpn; }; -#define MLX5_FTE_MATCH_PARAM_RESERVED reserved_at_e00 -/* Calculate the fte_match_param length and without the reserved length. -* Make sure the reserved field is the last. -*/ -#define MLX5_ST_SZ_DW_MATCH_PARAM \ - ((MLX5_BYTE_OFF(fte_match_param, MLX5_FTE_MATCH_PARAM_RESERVED) / sizeof(u32)) + \ - BUILD_BUG_ON_ZERO(MLX5_ST_SZ_BYTES(fte_match_param) != \ - MLX5_FLD_SZ_BYTES(fte_match_param, \ - MLX5_FTE_MATCH_PARAM_RESERVED) +\ - MLX5_BYTE_OFF(fte_match_param, \ - MLX5_FTE_MATCH_PARAM_RESERVED))) +#define MLX5_ST_SZ_DW_MATCH_PARAM MLX5_ST_SZ_DW(fte_match_param)struct fs_fte_action {int modify_mask;
include/linux/mlx5/device.h +1 -0
@@ -1171,6 +1171,7 @@ enum {MLX5_MATCH_MISC_PARAMETERS_3 =1 <<4 ,MLX5_MATCH_MISC_PARAMETERS_4 =1 <<5 ,MLX5_MATCH_MISC_PARAMETERS_5 =1 <<6 , + MLX5_MATCH_MISC_PARAMETERS_6 = 1 << 7, }; enum {
include/linux/mlx5/mlx5_ifc.h +15 -2
@@ -508,7 +508,8 @@ struct mlx5_ifc_flow_table_prop_layout_bits {u8 reformat_l2_to_l3_audp_tunnel[0x1 ];u8 reformat_l3_audp_tunnel_to_l2[0x1 ];u8 ignore_flow_level_rtc_valid[0x1 ]; -u8 reserved_at_70[0x8 ]; +u8 reserved_at_70[0x7 ]; +u8 reformat_del_psp_transport[0x1 ];u8 log_max_ft_num[0x8 ];u8 reserved_at_80[0x10 ];
@@ -798,6 +799,15 @@ struct mlx5_ifc_fte_match_set_misc5_bits {u8 reserved_at_100[0x100 ]; }; +struct mlx5_ifc_fte_match_set_misc6_bits { +u8 reserved_at_0[0x1a ]; +u8 psp_version[0x4 ]; +u8 reserved_at_1e[0x2 ]; + +u8 reserved_at_20[0x1e0 ]; +}; + +struct mlx5_ifc_cmd_pas_bits {u8 pa_h[0x20 ];
@@ -2339,7 +2349,7 @@ struct mlx5_ifc_fte_match_param_bits {struct mlx5_ifc_fte_match_set_misc5_bits misc_parameters_5; -u8 reserved_at_e00[0x200 ]; +struct mlx5_ifc_fte_match_set_misc6_bits misc_parameters_6; };enum {
@@ -6984,6 +6994,7 @@ enum {MLX5_QUERY_FLOW_GROUP_IN_MATCH_CRITERIA_ENABLE_MISC_PARAMETERS_3 =0x4 ,MLX5_QUERY_FLOW_GROUP_IN_MATCH_CRITERIA_ENABLE_MISC_PARAMETERS_4 =0x5 ,MLX5_QUERY_FLOW_GROUP_IN_MATCH_CRITERIA_ENABLE_MISC_PARAMETERS_5 =0x6 , + MLX5_QUERY_FLOW_GROUP_IN_MATCH_CRITERIA_ENABLE_MISC_PARAMETERS_6 = 0x7, }; struct mlx5_ifc_query_flow_group_out_bits {
@@ -7245,6 +7256,7 @@ enum mlx5_reformat_ctx_type {MLX5_REFORMAT_TYPE_REMOVE_HDR =0x10 ,MLX5_REFORMAT_TYPE_ADD_MACSEC =0x11 ,MLX5_REFORMAT_TYPE_DEL_MACSEC =0x12 , + MLX5_REFORMAT_TYPE_REMOVE_PSP_TRANSPORT = 0x16, }; struct mlx5_ifc_alloc_packet_reformat_context_in_bits {
@@ -7368,6 +7380,7 @@ enum {MLX5_ACTION_IN_FIELD_OUT_EMD_47_32 =0x6F ,MLX5_ACTION_IN_FIELD_OUT_EMD_31_0 =0x70 ,MLX5_ACTION_IN_FIELD_PSP_SYNDROME =0x71 , + MLX5_ACTION_IN_FIELD_PSP_HEADER_1 = 0x78, }; struct mlx5_ifc_alloc_modify_header_context_out_bits {
Signature · 1 line
2.44.0
Quoted 13 lines · Tariq Toukan
Hi,
This series contains mlx5 shared updates.
Regards,
TariqCosmin Ratiu (1):
net/mlx5: ifc: Add PSP related fieldsShay Drory (1):
net/mlx5: Drop redundantesw_cap, reusee_switch_cap
Quoted 8 lines
.../net/ethernet/mellanox/mlx5/core/fs_core.h | 12 +----- .../mellanox/mlx5/core/steering/hws/cmd.c | 6 +-- include/linux/mlx5/device.h | 1 + include/linux/mlx5/mlx5_ifc.h | 38 ++++++++++--------- 4 files changed, 25 insertions(+), 32 deletions(-)base-commit:
ddbddbf8aee54bee038149187270c93a45478473
For the series:
Leon Romanovsky
AppliedQuoted 9 lines · Tariq Toukan
This series contains mlx5 shared updates.
Regards,
TariqCosmin Ratiu (1):
net/mlx5: ifc: Add PSP related fields[...]
Applied, thanks!
[1/2] net/mlx5: Drop redundant esw_cap, reuse e_switch_cap
https://git.kernel.org/rdma/rdma/c/0b7b17502300f7 [2/2] net/mlx5: ifc: Add PSP related fields https://git.kernel.org/rdma/rdma/c/bee40a7d0bd126
Best regards,
Signature · 1 line
Leon Romanovsky <[email protected]>
Leon Romanovsky
AppliedQuoted 9 lines · Tariq Toukan
This series contains mlx5 shared updates.
Regards,
TariqCosmin Ratiu (1):
net/mlx5: ifc: Add PSP related fields[...]
Applied, thanks!
[1/2] net/mlx5: Drop redundant esw_cap, reuse e_switch_cap
https://git.kernel.org/rdma/rdma/c/0b7b17502300f7 [2/2] net/mlx5: ifc: Add PSP related fields https://git.kernel.org/rdma/rdma/c/bee40a7d0bd126
Best regards,
Signature · 1 line
Leon Romanovsky <[email protected]>