.o
) files at compile time. Documentation/core-api/asm-annotations.rst
, objtool
can Documentation/arch/x86/orc-unwinder.rst
) CONFIG_OBJTOOL
must be set. objtool <actions> [<options>] file.o
-h | --hacks[=<jump_label,noinstr,skylake>] | patch toolchain bugs/limitations |
-i | --ibt | validate and annotate IBT |
-l | --sls | validate straight-line-speculation mitigations |
-m | --mcount | annotate mcount/fentry calls for ftrace |
-n | --noinstr | validate noinstr rules |
-o | --orc | generate ORC metadata |
-r | --retpoline | validate and annotate retpoline usage |
-s | --stackval | validate frame pointer rules |
-t | --static-call | annotate static calls |
-u | --uaccess | validate uaccess rules for SMAP |
--cfi | annotate kernel control flow integrity (kCFI) function preambles | |
--dump[=<orc>] | dump metadata | |
--prefix <n> | generate prefix symbols | |
--rethunk | validate and annotate rethunk usage | |
--unret | validate entry unret placement |
-v | --verbose | verbose warnings |
--backtrace | unwind on error | |
--backup | create .orig files before modification | |
--dry-run | don't write modifications | |
--link | object is a linked object | |
--mnop | nop out mcount call sites | |
--module | object is part of a kernel module | |
--no-unreachable | skip 'unreachable instruction' warnings | |
--sec-address | print section addresses in warnings | |
--stats | print statistics |
objtool
executable is used (for example?) to produce vmlinux.o
. include/linux/objtool.h
, include/linux/compiler.h