kernel_samsung_a53x/drivers/nvme/host
Nilay Shroff 2cfd472049 nvme: find numa distance only if controller has valid numa id
[ Upstream commit 863fe60ed27f2c85172654a63c5b827e72c8b2e6 ]

On system where native nvme multipath is configured and iopolicy
is set to numa but the nvme controller numa node id is undefined
or -1 (NUMA_NO_NODE) then avoid calculating node distance for
finding optimal io path. In such case we may access numa distance
table with invalid index and that may potentially refer to incorrect
memory. So this patch ensures that if the nvme controller numa node
id is -1 then instead of calculating node distance for finding optimal
io path, we set the numa node distance of such controller to default 10
(LOCAL_DISTANCE).

Link: https://lore.kernel.org/all/20240413090614.678353-1-nilay@linux.ibm.com/
Signed-off-by: Nilay Shroff <nilay@linux.ibm.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Signed-off-by: Keith Busch <kbusch@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-19 12:26:52 +01:00
..
core.c nvme-core: check for too small lba shift 2024-11-18 12:12:12 +01:00
fabrics.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fabrics.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fault_inject.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fc.c nvme-fc: do not wait in vain when unloading module 2024-11-18 22:25:33 +01:00
fc.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
hwmon.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kconfig Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
lightnvm.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
multipath.c nvme: find numa distance only if controller has valid numa id 2024-11-19 12:26:52 +01:00
nvme.h nvme: introduce helper function to get ctrl state 2024-11-18 12:12:15 +01:00
pci.c drivers/nvme: Add quirks for device 126f:2262 2024-11-19 09:23:15 +01:00
rdma.c nvme-rdma: do not try to stop unallocated queues 2024-11-08 11:26:19 +01:00
tcp.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
trace.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
trace.h Revert "nvme: use command_id instead of req->tag in trace_nvme_complete_rq()" 2024-11-18 12:12:11 +01:00
zns.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00