]> Gentwo Git Trees - linux/.git/commit
net/mlx5e: Prevent WQE metadata conflicts between timestamping and offloads
authorCarolina Jubran <cjubran@nvidia.com>
Thu, 11 Sep 2025 07:10:19 +0000 (10:10 +0300)
committerLeon Romanovsky <leon@kernel.org>
Wed, 17 Sep 2025 08:38:10 +0000 (04:38 -0400)
commit2ac207381c37eebc49559634ce5642119784bc7c
tree11693479ab516193ca6b334ce498cf2b36d76d4c
parentcce65f32443b61db2370a67d2e92d16b773fe8a4
net/mlx5e: Prevent WQE metadata conflicts between timestamping and offloads

Update the WQE metadata assignment to avoid overriding existing
metadata when setting the sysport timestamp ID. Since timestamp IDs are
limited to 256 values, they use only the lower 8 bits of the metadata
field.

To avoid conflicts, move IPsec and MACsec metadata ID to bits 8 and 9,
and shift the MACsec fs_id accordingly. This ensures safe coexistence
of timestamping and offload features that use the same metadata field.

Signed-off-by: Carolina Jubran <cjubran@nvidia.com>
Reviewed-by: Jianbo Liu <jianbol@nvidia.com>
Reviewed-by: Patrisious Haddad <phaddad@nvidia.com>
Reviewed-by: Dragos Tatulea <dtatulea@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Link: https://patch.msgid.link/1757574619-604874-4-git-send-email-tariqt@nvidia.com
Reviewed-by: Simon Horman <horms@kernel.org>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/en_tx.c
drivers/net/ethernet/mellanox/mlx5/core/lib/macsec_fs.c
include/linux/mlx5/qp.h