summaryrefslogtreecommitdiffstats
path: root/tools/objtool/arch
diff options
context:
space:
mode:
authorPeter Zijlstra <peterz@infradead.org>2021-02-11 13:03:28 +0100
committerIngo Molnar <mingo@kernel.org>2021-03-06 12:44:22 +0100
commitd54dba41999498b38a40940e1123019d50b26496 (patch)
treec1025dcdb0eb8c6b353913514db3149486b1e535 /tools/objtool/arch
parentLinux 5.12-rc2 (diff)
downloadlinux-d54dba41999498b38a40940e1123019d50b26496.tar.xz
linux-d54dba41999498b38a40940e1123019d50b26496.zip
objtool: Allow UNWIND_HINT to suppress dodgy stack modifications
rewind_stack_do_exit() UNWIND_HINT_FUNC /* Prevent any naive code from trying to unwind to our caller. */ xorl %ebp, %ebp movq PER_CPU_VAR(cpu_current_top_of_stack), %rax leaq -PTREGS_SIZE(%rax), %rsp UNWIND_HINT_REGS call do_exit Does unspeakable things to the stack, which objtool currently fails to detect due to a limitation in instruction decoding. This will be rectified after which the above will result in: arch/x86/entry/entry_64.o: warning: objtool: .text+0xab: unsupported stack register modification Allow the UNWIND_HINT on the next instruction to suppress this, it will overwrite the state anyway. Suggested-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Tested-by: Nick Desaulniers <ndesaulniers@google.com> Link: https://lkml.kernel.org/r/20210211173626.918498579@infradead.org
Diffstat (limited to 'tools/objtool/arch')
0 files changed, 0 insertions, 0 deletions