Re: [PATCH 0/2] sparc64: D-cache alias flushing fixes
From: Imre Kaloz
Date: Mon Sep 28 2026 - 04:57:22 EST
Hi Adrian,
On Sun, 27 Sep 2026, John Paul Adrian Glaubitz wrote:
On Sun, 2026-09-27 at 12:55 +0200, Imre Kaloz wrote:
Two fixes to D-cache alias flushing on sparc64 CPUs with a virtually
indexed L1 D-cache.
Patch 1 makes move_pte() and tlb_batch_add() flush only the page a PTE
maps, instead of every page of its folio once per PTE, so the number
of cross-calls for an mremap() of a large folio no longer grows with
the square of its size.
Patch 2 implements flush_cache_vmap() and flush_cache_vunmap(), which
have been no-ops on sparc64. Stale lines left by a vmalloc mapping
corrupt BPF programs and module data on UltraSPARC III. It uses
flush_dcache_page_all() as patch 1 restores it.
Both patches are tagged for stable. Tested on a Sun Ultra 45.
<snip>
Would you mind reporting the bugs that these patches fix in the sparclinux
issue tracker on GitHub [1]? The reason I'm asking is that there has been
recently a strong uptick of patches for SPARC and I want to make sure we're
not missing any when Andreas gets back to reviewing patches.
Was going to do that. For two days my U45 seems finally rock solid after many years.
Best,
Imre