linux-stable/arch/x86
Sean Christopherson fd8547ebc1 cpu: Re-enable CPU mitigations by default for !X86 architectures
commit fe42754b94 upstream.

Rename x86's to CPU_MITIGATIONS, define it in generic code, and force it
on for all architectures exception x86.  A recent commit to turn
mitigations off by default if SPECULATION_MITIGATIONS=n kinda sorta
missed that "cpu_mitigations" is completely generic, whereas
SPECULATION_MITIGATIONS is x86-specific.

Rename x86's SPECULATIVE_MITIGATIONS instead of keeping both and have it
select CPU_MITIGATIONS, as having two configs for the same thing is
unnecessary and confusing.  This will also allow x86 to use the knob to
manage mitigations that aren't strictly related to speculative
execution.

Use another Kconfig to communicate to common code that CPU_MITIGATIONS
is already defined instead of having x86's menu depend on the common
CPU_MITIGATIONS.  This allows keeping a single point of contact for all
of x86's mitigations, and it's not clear that other architectures *want*
to allow disabling mitigations at compile-time.

Fixes: f337a6a21e ("x86/cpu: Actually turn off mitigations by default for SPECULATION_MITIGATIONS=n")
Closes: https://lkml.kernel.org/r/20240413115324.53303a68%40canb.auug.org.au
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Reported-by: Michael Ellerman <mpe@ellerman.id.au>
Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Sean Christopherson <seanjc@google.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Acked-by: Josh Poimboeuf <jpoimboe@kernel.org>
Acked-by: Borislav Petkov (AMD) <bp@alien8.de>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20240420000556.2645001-2-seanjc@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-05-02 16:35:28 +02:00
..
boot x86/efistub: Remap kernel text read-only before dropping NX attribute 2024-04-10 16:38:23 +02:00
coco x86/coco: Require seeding RNG with RDRAND on CoCo systems 2024-04-10 16:38:19 +02:00
configs hardening updates for v6.7-rc1 2023-10-30 19:09:55 -10:00
crypto This update includes the following changes: 2024-01-10 12:23:43 -08:00
entry x86/vdso: Fix rethunk patching for vdso-image-x32.o too 2024-04-13 13:10:12 +02:00
events perf/x86: Fix out of range data 2024-04-17 11:23:39 +02:00
hyperv x86/hyperv: Use per cpu initial stack for vtl context 2024-03-26 18:17:30 -04:00
ia32
include x86/tdx: Preserve shared bit on mprotect() 2024-05-02 16:35:27 +02:00
kernel x86/cpu: Fix check for RDPKRU in __show_regs() 2024-05-02 16:35:24 +02:00
kvm KVM: x86/pmu: Set enable bits for GP counters in PERF_GLOBAL_CTRL at "RESET" 2024-05-02 16:35:23 +02:00
lib x86/boot: Move mem_encrypt= parsing to the decompressor 2024-04-10 16:38:23 +02:00
math-emu
mm x86/sme: Move early SME kernel encryption handling into .head.text 2024-04-10 16:38:23 +02:00
net x86/bpf: Fix IP after emitting call depth accounting 2024-04-10 16:38:01 +02:00
pci PCI: Disable D3cold on Asus B1400 PCI-NVMe bridge 2024-04-13 13:10:06 +02:00
platform x86/xen: attempt to inflate the memory balloon on PVH 2024-04-13 13:10:10 +02:00
power mm/treewide: replace pud_large() with pud_leaf() 2024-04-10 16:38:00 +02:00
purgatory
ras
realmode x86/cleanups changes for v6.8: 2024-01-08 17:23:32 -08:00
tools x86, relocs: Ignore relocations in .notes section 2024-03-26 18:16:51 -04:00
um This pull request contains the following changes for UML: 2024-01-17 10:44:34 -08:00
video
virt x86/mce: Differentiate real hardware #MCs from TDX erratum ones 2023-12-12 08:46:46 -08:00
xen x86/xen: attempt to inflate the memory balloon on PVH 2024-04-13 13:10:10 +02:00
.gitignore
Kbuild
Kconfig cpu: Re-enable CPU mitigations by default for !X86 architectures 2024-05-02 16:35:28 +02:00
Kconfig.assembler
Kconfig.cpu x86/Kconfig: Transmeta Crusoe is CPU family 5, not 6 2024-02-09 16:28:19 +01:00
Kconfig.debug
Makefile kbuild: use 4-space indentation when followed by conditionals 2024-02-15 06:05:44 +09:00
Makefile.postlink kbuild: remove ARCH_POSTLINK from module builds 2023-10-28 21:10:08 +09:00
Makefile.um
Makefile_32.cpu