Closed yaobinwen closed 6 years ago
The Stack Overflow page [1] has a lot of information about it. Here are the major points:
retpoline
is "a special code sequence ... that can do indirect calls without speculation" to avoid the Spectre Attacks
[3].retpoline
, the compiler that compiles the Linux kernel code must be configured to use the -mindirect-branch=thunk-extern
option. After the compilation, the kernel's vermagic
will include the string "retpoline
".vermagic
lines with the kernel's vermagic
, which further requires:
retpoline
compilation, such as g++-7
.dkms
package is recommended because it automatically rebuilds the drivers' kernel modules when a newer (or older) kernel is installed.References:
What is
retpoline
all about?