[PATCH 00/24] objtool: retpoline and asm-goto validation

From: Peter Zijlstra
Date: Tue Jan 23 2018 - 10:49:08 EST


This series adds two features to objtool:

- retpoline validation; it verifies no indirect jumps/calls are left in
CONFIG_RETPOLINE=y builds.

includes fixups for kvm and others

- asm-goto validation; allows asserting that a block of code is not reachable
through a dynamic branch.

After this it forces an asm-goto capable compiler to build arch/x86 and removes
the fallback code for static_cpu_has(). After which we can use static_cpu_has()
to guarantee a lack of dynamic branches, which is a requested feature for
various spectre related things.