linux/arch
Josh Poimboeuf b6a2cd26bc x86/bugs: Don't fill RSB on context switch with eIBRS
[ Upstream commit 27ce8299bc ]

User->user Spectre v2 attacks (including RSB) across context switches
are already mitigated by IBPB in cond_mitigation(), if enabled globally
or if either the prev or the next task has opted in to protection.  RSB
filling without IBPB serves no purpose for protecting user space, as
indirect branches are still vulnerable.

User->kernel RSB attacks are mitigated by eIBRS.  In which case the RSB
filling on context switch isn't needed, so remove it.

Suggested-by: Pawan Gupta <pawan.kumar.gupta@linux.intel.com>
Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Reviewed-by: Pawan Gupta <pawan.kumar.gupta@linux.intel.com>
Reviewed-by: Amit Shah <amit.shah@amd.com>
Reviewed-by: Nikolay Borisov <nik.borisov@suse.com>
Link: https://lore.kernel.org/r/98cdefe42180358efebf78e3b80752850c7a3e1b.1744148254.git.jpoimboe@kernel.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
History 2025-05-02 07:44:37 +02:00
..
alpha alpha/elf: Fix misc/setarch test of util-linux by removing 32bit support 2025-04-10 14:31:50 +02:00
arc ARC: build: Try to guess GCC variant of cross compiler 2025-01-09 13:28:49 +01:00
arm ARM: Remove address checking for MMUless devices 2025-04-10 14:31:56 +02:00
arm64 KVM: arm64: Eagerly switch ZCR_EL{1,2} 2025-05-02 07:44:17 +02:00
csky csky, hexagon: fix broken sys_sync_file_range 2024-07-05 09:14:48 +02:00
h8300 h8300: Fix build errors from do_exit() to make_task_dead() transition 2023-02-01 08:27:21 +01:00
hexagon hexagon: Fix unbalanced spinlock in die() 2025-03-13 12:50:14 +01:00
ia64 arch: Introduce CONFIG_FUNCTION_ALIGNMENT 2024-04-10 16:18:49 +02:00
m68k m68k: vga: Fix I/O defines 2025-03-13 12:50:23 +01:00
microblaze microblaze: don't treat zero reserved memory regions as error 2024-10-17 15:10:38 +02:00
mips MIPS: cm: Detect CM quirks from device tree 2025-05-02 07:44:34 +02:00
nds32 exit: Add and use make_task_dead. 2023-02-01 08:27:20 +01:00
nios2 nios2: dts: Fix tse_mac "max-frame-size" property 2023-06-21 15:59:14 +02:00
openrisc openrisc: Call setup_memory() earlier in the init sequence 2024-09-04 13:23:27 +02:00
parisc parisc: PDT: Fix missing prototype warning 2025-05-02 07:44:34 +02:00
powerpc powerpc/rtas: Prevent Spectre v1 gadget construction in sys_rtas() 2025-05-02 07:44:19 +02:00
riscv riscv: Avoid fortify warning in syscall_get_arguments() 2025-05-02 07:44:13 +02:00
s390 KVM: s390: Don't use %pK through tracepoints 2025-05-02 07:44:36 +02:00
sh sh: cpuinfo: Fix a warning for CONFIG_CPUMASK_OFFSTACK 2024-12-14 19:51:16 +01:00
sparc sparc/mm: disable preemption in lazy mmu mode 2025-05-02 07:44:04 +02:00
um um: Always dump trace for specified task in show_stack 2024-12-14 19:51:19 +01:00
x86 x86/bugs: Don't fill RSB on context switch with eIBRS 2025-05-02 07:44:37 +02:00
xtensa xtensa: boot/lib: fix function prototypes 2023-10-06 13:18:14 +02:00
.gitignore .gitignore: prefix local generated files with a slash 2021-05-02 00:43:35 +09:00
Kconfig cpu: Re-enable CPU mitigations by default for !X86 architectures 2024-05-02 16:24:48 +02:00