diff options
author | Peter Zijlstra <[email protected]> | 2021-10-26 14:01:42 +0200 |
---|---|---|
committer | Peter Zijlstra <[email protected]> | 2021-10-28 23:25:27 +0200 |
commit | 7508500900814d14e2e085cdc4e28142721abbdf (patch) | |
tree | 4776ae7d32fa640324f929a0bb23bfd56a86e1bc /net/lapb/lapb_timer.c | |
parent | 1a6f74429c42a3854980359a758e222005712aee (diff) |
x86/alternative: Implement .retpoline_sites support
Rewrite retpoline thunk call sites to be indirect calls for
spectre_v2=off. This ensures spectre_v2=off is as near to a
RETPOLINE=n build as possible.
This is the replacement for objtool writing alternative entries to
ensure the same and achieves feature-parity with the previous
approach.
One noteworthy feature is that it relies on the thunks to be in
machine order to compute the register index.
Specifically, this does not yet address the Jcc __x86_indirect_thunk_*
calls generated by clang, a future patch will add this.
Signed-off-by: Peter Zijlstra (Intel) <[email protected]>
Reviewed-by: Borislav Petkov <[email protected]>
Acked-by: Josh Poimboeuf <[email protected]>
Tested-by: Alexei Starovoitov <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'net/lapb/lapb_timer.c')
0 files changed, 0 insertions, 0 deletions