linux-yocto/arch/x86/lib
Pawan Gupta 4754e29f43 x86/its: Add support for ITS-safe return thunk
commit a75bf27fe4 upstream.

RETs in the lower half of cacheline may be affected by ITS bug,
specifically when the RSB-underflows. Use ITS-safe return thunk for such
RETs.

RETs that are not patched:

- RET in retpoline sequence does not need to be patched, because the
  sequence itself fills an RSB before RET.
- RET in Call Depth Tracking (CDT) thunks __x86_indirect_{call|jump}_thunk
  and call_depth_return_thunk are not patched because CDT by design
  prevents RSB-underflow.
- RETs in .init section are not reachable after init.
- RETs that are explicitly marked safe with ANNOTATE_UNRET_SAFE.

Signed-off-by: Pawan Gupta <pawan.kumar.gupta@linux.intel.com>
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
Reviewed-by: Josh Poimboeuf <jpoimboe@kernel.org>
Reviewed-by: Alexandre Chartre <alexandre.chartre@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-05-18 08:24:11 +02:00
..
.gitignore
atomic64_32.c
atomic64_386_32.S
atomic64_cx8_32.S
cache-smp.c
checksum_32.S
clear_page_64.S
cmdline.c
cmpxchg8b_emu.S
cmpxchg16b_emu.S
copy_mc_64.S
copy_mc.c
copy_page_64.S
copy_user_64.S x86/uaccess: Improve performance by aligning writes to 8 bytes in copy_user_generic(), on non-FSRM/ERMS CPUs 2025-04-10 14:37:39 +02:00
copy_user_uncached_64.S
cpu.c
csum-copy_64.S
csum-partial_64.c
csum-wrappers_64.c
delay.c
error-inject.c
getuser.S
hweight.S
inat.c
insn-eval.c
insn.c
iomap_copy_64.S
iomem.c
kaslr.c
Makefile
memcpy_32.c
memcpy_64.S
memmove_32.S
memmove_64.S
memset_64.S
misc.c
msr-reg-export.c
msr-reg.S
msr-smp.c
msr.c
pc-conf-reg.c
putuser.S
retpoline.S x86/its: Add support for ITS-safe return thunk 2025-05-18 08:24:11 +02:00
string_32.c
strstr_32.c
usercopy_32.c
usercopy_64.c
usercopy.c
x86-opcode-map.txt