]> git.baikalelectronics.ru Git - kernel.git/commit
x86/speculation: Rename RETPOLINE_AMD to RETPOLINE_LFENCE
authorPeter Zijlstra (Intel) <peterz@infradead.org>
Wed, 16 Feb 2022 19:57:00 +0000 (20:57 +0100)
committerBorislav Petkov <bp@suse.de>
Mon, 21 Feb 2022 09:21:28 +0000 (10:21 +0100)
commit1f21bd33365f471ee9e4d03623cf8f844e09ff3c
tree98281d1b3a28e433a6117013397440e98e5de330
parent14248f540c2a63979cc0b6d26ba6756218d81baf
x86/speculation: Rename RETPOLINE_AMD to RETPOLINE_LFENCE

The RETPOLINE_AMD name is unfortunate since it isn't necessarily
AMD only, in fact Hygon also uses it. Furthermore it will likely be
sufficient for some Intel processors. Therefore rename the thing to
RETPOLINE_LFENCE to better describe what it is.

Add the spectre_v2=retpoline,lfence option as an alias to
spectre_v2=retpoline,amd to preserve existing setups. However, the output
of /sys/devices/system/cpu/vulnerabilities/spectre_v2 will be changed.

  [ bp: Fix typos, massage. ]

Co-developed-by: Josh Poimboeuf <jpoimboe@redhat.com>
Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Borislav Petkov <bp@suse.de>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
arch/x86/include/asm/cpufeatures.h
arch/x86/include/asm/nospec-branch.h
arch/x86/kernel/alternative.c
arch/x86/kernel/cpu/bugs.c
arch/x86/lib/retpoline.S
arch/x86/net/bpf_jit_comp.c
tools/arch/x86/include/asm/cpufeatures.h