summaryrefslogtreecommitdiffstats
path: root/tools/objtool/check.c
diff options
context:
space:
mode:
authorMiroslav Benes <mbenes@suse.cz>2020-04-24 16:30:42 +0200
committerPeter Zijlstra <peterz@infradead.org>2020-04-30 20:14:33 +0200
commitb490f45362002fef57996388e395efc974b013f4 (patch)
tree2c436e0e83e3c8af5ebaac541352fd0b8ed494db /tools/objtool/check.c
parentb09fb65e863733e192d4825a285b4b4998969ce0 (diff)
downloadlinux-stable-b490f45362002fef57996388e395efc974b013f4.tar.gz
linux-stable-b490f45362002fef57996388e395efc974b013f4.tar.bz2
linux-stable-b490f45362002fef57996388e395efc974b013f4.zip
objtool: Move the IRET hack into the arch decoder
Quoting Julien: "And the other suggestion is my other email was that you don't even need to add INSN_EXCEPTION_RETURN. You can keep IRET as INSN_CONTEXT_SWITCH by default and x86 decoder lookups the symbol conaining an iret. If it's a function symbol, it can just set the type to INSN_OTHER so that it caries on to the next instruction after having handled the stack_op." Suggested-by: Julien Thierry <jthierry@redhat.com> Signed-off-by: Miroslav Benes <mbenes@suse.cz> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Miroslav Benes <mbenes@suse.cz> Acked-by: Josh Poimboeuf <jpoimboe@redhat.com> Link: https://lkml.kernel.org/r/20200428191659.913283807@infradead.org
Diffstat (limited to 'tools/objtool/check.c')
-rw-r--r--tools/objtool/check.c11
1 files changed, 0 insertions, 11 deletions
diff --git a/tools/objtool/check.c b/tools/objtool/check.c
index 4f3db2f58c56..d822858764fe 100644
--- a/tools/objtool/check.c
+++ b/tools/objtool/check.c
@@ -2320,17 +2320,6 @@ static int validate_branch(struct objtool_file *file, struct symbol *func,
break;
- case INSN_EXCEPTION_RETURN:
- /*
- * This handles x86's sync_core() case, where we use an
- * IRET to self. All 'normal' IRET instructions are in
- * STT_NOTYPE entry symbols.
- */
- if (func)
- break;
-
- return 0;
-
case INSN_CONTEXT_SWITCH:
if (func && (!next_insn || !next_insn->hint)) {
WARN_FUNC("unsupported instruction in callable function",