linux/kernel/dma
Petr Tesarik 22d0213e55 dma-direct: fix use of max_pfn
Calculate the correct physical address of the last byte of memory. Since
max_pfn is in fact "the PFN of the first page after the highest system RAM
in physical address space", the highest address that might be used for a
DMA buffer is one byte below max_pfn << PAGE_SHIFT.

This fix is unlikely to make any difference in practice. It's just that the
current formula is slightly confusing.

Signed-off-by: Petr Tesarik <ptesarik@suse.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Link: https://lore.kernel.org/r/20260410113506.262579-1-ptesarik@suse.com
2026-04-30 08:21:34 +02:00
..
coherent.c of: reserved_mem: switch to ops based OF_DECLARE() 2026-03-26 14:12:02 -05:00
contiguous.c Merge branch 'dma-contig-for-7.1-modules-prep-v4' into dma-mapping-for-next 2026-03-31 14:52:03 +02:00
debug.c dma-debug: suppress cacheline overlap warning when arch has no DMA alignment requirement 2026-03-30 09:41:18 +02:00
debug.h dma-mapping: export new dma_*map_phys() interface 2025-09-12 00:18:21 +02:00
direct.c dma-direct: fix use of max_pfn 2026-04-30 08:21:34 +02:00
direct.h dma-mapping: introduce DMA_ATTR_CC_SHARED for shared memory 2026-04-02 07:29:33 +02:00
dummy.c dma-mapping: convert dummy ops to physical address mapping 2025-10-29 10:27:29 +01:00
Kconfig dma-mapping: Separate DMA sync issuing and completion waiting 2026-03-13 23:47:31 +01:00
Makefile dma-mapping: clearly mark DMA ops as an architecture feature 2024-09-04 07:08:51 +03:00
map_benchmark.c dma-mapping: benchmark: add support for dma_map_sg 2026-03-04 11:22:05 +01:00
mapping.c dma-mapping: introduce DMA_ATTR_CC_SHARED for shared memory 2026-04-02 07:29:33 +02:00
ops_helpers.c dma-mapping: remove unused map_page callback 2025-10-29 10:27:31 +01:00
pool.c dma/pool: distinguish between missing and exhausted atomic pools 2026-01-29 10:23:45 +01:00
remap.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
swiotlb.c memblock: updates for 7.0-rc1 2026-04-18 11:29:14 -07:00