summaryrefslogtreecommitdiff
path: root/scripts/git.orderFile
diff options
context:
space:
mode:
authorAlexander Graf <graf@amazon.com>2026-08-21 22:42:52 +0000
committerMarek Szyprowski <m.szyprowski@samsung.com>2026-08-24 15:40:07 +0200
commit1476cca098f6d3a553fcec6fe9b7d86e15c00b59 (patch)
tree5059c2f31ca2b0fc9ac36a64ba0cdfaac7778846 /scripts/git.orderFile
parent121f9fd1c3083312055126205f3e40b8ee999fe6 (diff)
downloadlinux-1476cca098f6d3a553fcec6fe9b7d86e15c00b59.tar.gz
linux-1476cca098f6d3a553fcec6fe9b7d86e15c00b59.zip
dma-contiguous: fix truncation of numa_cma / cma_pernuma sizes >= 2G
numa_cma=0:4G reserves nothing at all. dma_numa_cma_reserve() copies the requested size into a local int before handing it to cma_declare_contiguous_nid(), so 0x100000000 truncates to zero and the loop skips the node silently. Both parameters are documented in kernel-parameters.txt as nn[MG], so that is the syntax the documentation invites. Which bits survive decides what a request turns into: 4G, 8G and 16G reserve nothing, 2G, 3G and 6G sign-extend into a size the allocator rejects with a warning, and 5G quietly reserves 1G. It reaches further than those parameters. On a CMA_SIZE_PERNUMA kernel with no per-node parameter, dma_numa_cma_reserve() takes the per-node size from the default area, so a plain cma=4G on a multi-node machine feeds that size through the same local and loses every per-node area. numa_cma_size[] and pernuma_size_bytes are both phys_addr_t, so use it for the local too, and give early_numa_cma() separate variables for the node id and the size while in there. Fixes: d5cae2261b86 ("dma-contiguous: simplify numa cma area handling") Cc: stable@vger.kernel.org Assisted-by: Kiro:claude-opus-5 Signed-off-by: Alexander Graf <graf@amazon.com> Reviewed-by: Feng Tang <feng.tang@linux.alibaba.com> Link: https://lore.kernel.org/r/20260821224252.70640-1-graf@amazon.com Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Diffstat (limited to 'scripts/git.orderFile')
0 files changed, 0 insertions, 0 deletions