Re: [PATCH v2] scsi: mpt3sas: avoid out-of-bounds cpumask_of_node() call in _base_assign_reply_queues()

From: Martin K. Petersen (Oracle)

Date: Wed Sep 02 2026 - 23:15:02 EST


On Tue, 25 Aug 2026 13:03:13 -0600, Ivy Lopez wrote:

> dev_to_node() can return NUMA_NO_NODE (-1) on systems without NUMA
> topology information for the PCI device, such as single-socket
> boards that don't expose device-to-node affinity. Passing -1
> directly into cpumask_of_node() indexes node_to_cpumask_map[-1],
> an out-of-bounds array read caught by UBSAN:
>
> UBSAN: array-index-out-of-bounds in arch/x86/include/asm/topology.h:72:28
> index -1 is out of range for type 'cpumask *[1024]'
>
> [...]

Applied to 7.3/scsi-fixes, thanks!

[1/1] scsi: mpt3sas: avoid out-of-bounds cpumask_of_node() call in _base_assign_reply_queues()
https://git.kernel.org/mkp/scsi/c/e0d26fe176a8

--
Martin K. Petersen