objtool: Convert insn type to enum
authorJosh Poimboeuf <jpoimboe@redhat.com>
Thu, 18 Jul 2019 01:36:56 +0000 (20:36 -0500)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 18 Jul 2019 19:01:10 +0000 (21:01 +0200)
commit9fe7b7642fe2c5158904d06fe31b740ca0695a01
tree6488c994de6e16016bc5ded0beaf5ace832d0837
parente65050b94d8c518fdbee572ea4ca6d352e1fda37
objtool: Convert insn type to enum

This makes it easier to add new instruction types.  Also it's hopefully
more robust since the compiler should warn about out-of-range enums.

Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Nick Desaulniers <ndesaulniers@google.com>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/0740e96af0d40e54cfd6a07bf09db0fbd10793cd.1563413318.git.jpoimboe@redhat.com
tools/objtool/arch.h
tools/objtool/arch/x86/decode.c
tools/objtool/check.c
tools/objtool/check.h