Thread (4 messages) flat view 4 messages, 3 authors, 7d ago

Re: [PATCH] ARM: dma-mapping: split cache maintenance at highmem boundary

From: "Arnd Bergmann" <arnd@arndb.de>
Date: 2026-09-09 07:25:24
Also in: linux-iommu, lkml

On Wed, Sep 9, 2026, at 08:44, Karl Mehltretter wrote:
dma_cache_maint_page() processes highmem pages one at a time, but passes
the complete remaining range to a cache operation when the current page
is lowmem. If a physically contiguous range starts in lowmem and crosses
into highmem, the operation continues beyond high_memory through virtual
addresses which do not map the highmem pages.

On a Raspberry Pi 400 running an ARM32 LPAE kernel, an 8 KiB scatterlist
entry crossing this boundary caused a deterministic data abort at f0000000
in v7_dma_clean_range().

Limit the crossing lowmem iteration to the end of its page. Subsequent
iterations advance page by page until the existing highmem path takes
over. Keep the bulk operation for ranges contained in lowmem.

Fixes: 43377453af83 ("[ARM] introduce dma_cache_maint_page()")
Cc: stable@vger.kernel.org
Assisted-by: LLM
Signed-off-by: Karl Mehltretter <redacted>
Hi Karl,

I can see how the fix addresses the problem, but I don't yet see
how you can arrive in this situation. What type of memory allocation
can produce a physically contiguous page range from multiple
zones?

      Arnd
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help