]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: ena: Fix redundant device NUMA node override
authorShay Agroskin <shayagr@amazon.com>
Tue, 28 May 2024 17:09:12 +0000 (20:09 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 16 Jun 2024 11:39:52 +0000 (13:39 +0200)
commit2292bfd243ae7a129fb4bb614dae1a30dd9df653
tree7ea31acbf838b375680177f8cf1ac85f12cf7220
parent477c137131ecd46215eac4c74934d0af272a38bf
net: ena: Fix redundant device NUMA node override

[ Upstream commit 2dc8b1e7177d4f49f492ce648440caf2de0c3616 ]

The driver overrides the NUMA node id of the device regardless of
whether it knows its correct value (often setting it to -1 even though
the node id is advertised in 'struct device'). This can lead to
suboptimal configurations.

This patch fixes this behavior and makes the shared memory allocation
functions use the NUMA node id advertised by the underlying device.

Fixes: 1738cd3ed342 ("net: ena: Add a driver for Amazon Elastic Network Adapters (ENA)")
Signed-off-by: Shay Agroskin <shayagr@amazon.com>
Link: https://lore.kernel.org/r/20240528170912.1204417-1-shayagr@amazon.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/amazon/ena/ena_com.c