net/mlx5: use numa_mem_id() for default frag buf allocations

Use the current CPU's local memory node when callers do not request a
specific NUMA node for mlx5_frag_buf allocations.

Signed-off-by: Nimrod Oren <noren@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Link: https://patch.msgid.link/20260514104925.337570-2-tariqt@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
Nimrod Oren 2026-05-14 13:49:24 +03:00 committed by Jakub Kicinski
parent 627ac78f27
commit 0e22229971

View File

@ -305,7 +305,7 @@ int mlx5_frag_buf_alloc_node(struct mlx5_core_dev *dev, int size,
struct mlx5_dma_pool *pool;
int pool_idx;
node = node == NUMA_NO_NODE ? first_online_node : node;
node = node == NUMA_NO_NODE ? numa_mem_id() : node;
buf->size = size;
buf->npages = DIV_ROUND_UP(size, PAGE_SIZE);