WSL2-Linux-Kernel/arch
Masami Hiramatsu 567a9fd867 kprobes/x86: Fix kprobes to skip prefixes correctly
Fix resume_execution() and is_IF_modifier() to skip x86
instruction prefixes correctly by using x86 instruction
attribute.

Without this fix, resume_execution() can't handle instructions
which have non-REX prefixes (REX prefixes are skipped). This
will cause unexpected kernel panic by hitting bad address when a
kprobe hits on two-byte ret (e.g. "repz ret" generated for
Athlon/K8 optimization), because it just checks "repz" and can't
recognize the "ret" instruction.

These prefixes can be found easily with x86 instruction
attribute. This patch introduces skip_prefixes() and uses it in
resume_execution() and is_IF_modifier() to skip prefixes.

Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
LKML-Reference: <4C298A6E.8070609@hitachi.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2010-06-29 10:43:41 +02:00
..
alpha Merge branch 'linus' into perf/core 2010-06-28 22:33:24 +02:00
arm Merge branch 'linus' into perf/core 2010-06-28 22:33:24 +02:00
avr32 arch: Implement local64_t 2010-06-09 11:12:36 +02:00
blackfin arch: Implement local64_t 2010-06-09 11:12:36 +02:00
cris Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
frv Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
h8300 Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
ia64 Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
m32r Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
m68k arch: Implement local64_t 2010-06-09 11:12:36 +02:00
m68knommu Merge branch 'for-35' of git://repo.or.cz/linux-kbuild 2010-06-01 08:55:52 -07:00
microblaze Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
mips Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
mn10300 Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
parisc Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
powerpc Merge branch 'linus' into perf/core 2010-06-28 22:33:24 +02:00
s390 Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
score arch: Implement local64_t 2010-06-09 11:12:36 +02:00
sh Merge branch 'linus' into perf/core 2010-06-28 22:33:24 +02:00
sparc Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
um um, hweight: Fix UML boot crash due to x86 optimized hweight 2010-06-10 15:24:30 -07:00
x86 kprobes/x86: Fix kprobes to skip prefixes correctly 2010-06-29 10:43:41 +02:00
xtensa Merge commit 'v2.6.35-rc3' into perf/core 2010-06-18 10:53:19 +02:00
.gitignore
Kconfig