[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240417001507.2264512-1-seanjc@google.com>
Date: Tue, 16 Apr 2024 17:15:05 -0700
From: Sean Christopherson <seanjc@...gle.com>
To: Jonathan Corbet <corbet@....net>, Thomas Gleixner <tglx@...utronix.de>, Ingo Molnar <mingo@...hat.com>,
Borislav Petkov <bp@...en8.de>, Dave Hansen <dave.hansen@...ux.intel.com>, x86@...nel.org,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>, Peter Zijlstra <peterz@...radead.org>
Cc: linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org,
Stephen Rothwell <sfr@...b.auug.org.au>, Michael Ellerman <mpe@...erman.id.au>,
Geert Uytterhoeven <geert@...ux-m68k.org>, Sean Christopherson <seanjc@...gle.com>
Subject: [PATCH 0/2] cpu: Fix default mitigation behavior
This is effectively v2 of a previous series[*] that was intended to be
x86-only, but accidentally disabled CPU mitigations by default for every
other architectures. Unfortunately, the buggy code has already made it's
way to Linus' tree.
Patch 1 fixes that goof by adding a generic Kconfig to control the
default behavior.
Patch 2 disallows retroactively enabling mitigations via command line if
the kernel was built with CPU_MITIGATIONS=n, i.e. with
SPECULATION_MITIGATIONS=n on x86, as it's infeasible for the kernel to
provide sane, predictable behavior for this scenario.
[*] https://lore.kernel.org/all/20240409175108.1512861-1-seanjc@google.com
Sean Christopherson (2):
cpu: Re-enable CPU mitigations by default for !X86 architectures
cpu: Ignore "mitigations" kernel parameter if CPU_MITIGATIONS=n
Documentation/admin-guide/kernel-parameters.txt | 3 +++
arch/x86/Kconfig | 11 ++++++++---
drivers/base/Kconfig | 3 +++
kernel/cpu.c | 6 ++++--
4 files changed, 18 insertions(+), 5 deletions(-)
base-commit: 96fca68c4fbf77a8185eb10f7557e23352732ea2
--
2.44.0.683.g7961c838ac-goog
Powered by blists - more mailing lists