]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net/mlx5e: Pass netdev queue config to param calculations
authorDragos Tatulea <dtatulea@nvidia.com>
Mon, 23 Feb 2026 20:41:53 +0000 (22:41 +0200)
committerPaolo Abeni <pabeni@redhat.com>
Thu, 26 Feb 2026 09:54:24 +0000 (10:54 +0100)
commit585cfa99d3578db997423e79c9c99d4e5e428271
tree7c2550b41bd7994b41105a30edd7cc46399d75a6
parent0fa8c93357601cbfb7006a420fd3b63f4a06af11
net/mlx5e: Pass netdev queue config to param calculations

If set, take rx_page_size into consideration when calculating
the page shift in Multi Packet WQE mode.

The queue config is saved in the mlx5e_rq_opt_param struct which is
added to the mlx5e_channel_param struct. Now the configuration can be
read from the struct instead of adding it as an argument to all call
sites. For consistency, the queue config is assigned in
mlx5e_build_channel_param().

The queue configuration is read only from queue management ops
as that's the only place where it is currently useful. Furthermore,
netdev_queue_config() expects netdev->queue_mgmt_ops to be
set which is not always the case (representor netdevs).

Signed-off-by: Dragos Tatulea <dtatulea@nvidia.com>
Reviewed-by: Cosmin Ratiu <cratiu@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Link: https://patch.msgid.link/20260223204155.1783580-14-tariqt@nvidia.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/ethernet/mellanox/mlx5/core/en/params.c
drivers/net/ethernet/mellanox/mlx5/core/en/params.h
drivers/net/ethernet/mellanox/mlx5/core/en_main.c