Re: [PATCH v1] arm64: Mitigate Spectre v1 in the BPF interpreter
From: Catalin Marinas
Date: Fri Nov 20 2026 - 05:03:18 EST
On Thu, Nov 19, 2026 at 01:18:03AM +0000, Alexei Starovoitov wrote:
> On Tue, Nov 17, 2026 at 09:23 AM Ryan Roberts <ryan.roberts@xxxxxxx> wrote:
> > The arm64 JIT implements BPF_NOSPEC with a speculation barrier, but the
> > interpreter calls barrier_nospec(), which falls back to a no-op on
> > arm64. Programs executed by the interpreter therefore lack the
> > Spectre-v1 barriers assumed by the verifier. Contrary to the code
> > comment, kernel-wide SSBD does not provide this protection, since it
> > mitigates Spectre v4 rather than Spectre v1.
>
> Nack.
> In bpf-next arm64 has no interpreter when the JIT is built.
And what about current mainline/stable or when one disables BPF_JIT
explicitly? Should we force BPF_JIT=y as well when ALWAYS_ON=y?
--
Catalin