[PATCH] arm: asid: Do not replace active_asids if already 0

Catalin Marinas catalin.marinas at arm.com
Tue Aug 4 04:17:28 PDT 2026


On Sat, Jul 25, 2026 at 12:12:16PM +0200, Karl Mehltretter wrote:
> On Thu, Jan 04, 2018 at 06:04:05PM +0100, Catalin Marinas wrote:
> > This patch changes the xchg to cmpxchg so that the active_asids is only
> > updated if non-zero to avoid a race with an ASID roll-over on a
> > different CPU.
> > 
> > Cc: Russell King <linux at armlinux.org.uk>
> > Cc: Will Deacon <will.deacon at arm.com>
> > Signed-off-by: Catalin Marinas <catalin.marinas at arm.com>
> > ---
> > 
> > This is similar to the arm64 patch [1], with the difference that non-relaxed
> > (cmp)xchg is used as per the existing code.
> > 
> > [1] http://lkml.kernel.org/r/20180104111721.33834-1-catalin.marinas at arm.com
> 
> While the arm64 patch was reviewed and merged, this patch never got any reply.
> It needs a small rebase, but the change itself still applies today.

Oh, it's been a while. Not sure whether I missed cc'ing Russell at the
time or the archive stripped the recipients (I no longer have the actual
email sent).

> Would you like to resend it ? 

If you have the setup to test, please do check and resend it to the
list. After that you can send it to Russell's patch system:

  git send-email --add-header="KernelVersion: $(git describe --abbrev=0)" --to="patches at armlinux.org.uk"

The arm64 commit was a8ffaaa060b8 ("arm64: asid: Do not replace
active_asids if already 0").

Thanks.

-- 
Catalin



More information about the linux-arm-kernel mailing list