summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorCatalin Marinas <catalin.marinas@arm.com>2024-08-11 10:09:36 +0300
committerChristoph Hellwig <hch@lst.de>2024-08-22 06:18:11 +0200
commit3be9b846896d1d8b66040ece6e216cd58d03242e (patch)
treedb5d0331ad122026a9466f38c6d620af406db959 /kernel
parentba0fb44aed47693cc2482427f63ba6cd19051327 (diff)
arm64: support DMA zone above 4GB
Commit 791ab8b2e3db ("arm64: Ignore any DMA offsets in the max_zone_phys() calculation") made arm64 DMA/DMA32 zones span the entire RAM when RAM starts above 32-bits. This breaks hardware with DMA area that start above 32-bits. But the commit log says that "we haven't noticed any such hardware". It turns out that such hardware does exist. One such platform has RAM starting at 32GB with an internal bus that has the following DMA limits: #address-cells = <2>; #size-cells = <2>; dma-ranges = <0x00 0xc0000000 0x08 0x00000000 0x00 0x40000000>; That is, devices under this bus see 1GB of DMA range between 3GB-4GB in their address space. This range is mapped to CPU memory at 32GB-33GB. With current code DMA allocations for devices under this bus are not limited to DMA area, leading to run-time allocation failure. This commit reinstates DMA zone at the bottom of RAM. The result is DMA zone that properly reflects the hardware constraints as follows: [ 0.000000] Zone ranges: [ 0.000000] DMA [mem 0x0000000800000000-0x000000083fffffff] [ 0.000000] DMA32 empty [ 0.000000] Normal [mem 0x0000000840000000-0x0000000bffffffff] Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> [baruch: split off the original patch] Signed-off-by: Baruch Siach <baruch@tkos.co.il> Reviewed-by: Petr Tesarik <ptesarik@suse.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'kernel')
0 files changed, 0 insertions, 0 deletions