x86: Handle failures of parsing immediate operands in the instruction decoder
authorMasami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Fri, 13 Apr 2012 03:24:27 +0000 (12:24 +0900)
committerIngo Molnar <mingo@kernel.org>
Mon, 16 Apr 2012 06:56:11 +0000 (08:56 +0200)
commit6c7b8e82aab75a25581c4d446fc87f96634e9ef9
tree088f31f88c85a64304c171eced7b4233cbece6a9
parent7ea6411f4ceb62e5e53170d59d10996dca20c599
x86: Handle failures of parsing immediate operands in the instruction decoder

This can happen if the instruction is much longer than the maximum length,
or if insn->opnd_bytes is manually changed.

This patch also fixes warnings from -Wswitch-default flag.

Reported-by: Prashanth Nageshappa <prashanth@linux.vnet.ibm.com>
Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Cc: Jim Keniston <jkenisto@linux.vnet.ibm.com>
Cc: Linux-mm <linux-mm@kvack.org>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Christoph Hellwig <hch@infradead.org>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Arnaldo Carvalho de Melo <acme@infradead.org>
Cc: Anton Arapov <anton@redhat.com>
Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
Cc: yrl.pp-manager.tt@hitachi.com
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20120413032427.32577.42602.stgit@localhost.localdomain
Signed-off-by: Ingo Molnar <mingo@kernel.org>
arch/x86/lib/insn.c