diff options
author | Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> | 2012-03-05 08:32:16 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2012-03-06 03:49:49 -0500 |
commit | 464846888d9aad186cab3acdae6b654f9eb19772 (patch) | |
tree | fdf0b98237845a7d9af8a01cdf4971b43a2a3063 /lib/debugobjects.c | |
parent | 86b4ce3156c0dc140907ad03639564000cde694f (diff) |
x86/kprobes: Fix a bug which can modify kernel code permanently
Fix a bug in kprobes which can modify kernel code
permanently at run-time. In the result, kernel can
crash when it executes the modified code.
This bug can happen when we put two probes enough near
and the first probe is optimized. When the second probe
is set up, it copies a byte which is already modified
by the first probe, and executes it when the probe is hit.
Even worse, the first probe and the second probe are removed
respectively, the second probe writes back the copied
(modified) instruction.
To fix this bug, kprobes always recovers the original
code and copies the first byte from recovered instruction.
Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Cc: yrl.pp-manager.tt@hitachi.com
Cc: systemtap@sourceware.org
Cc: anderson@redhat.com
Link: http://lkml.kernel.org/r/20120305133215.5982.31991.stgit@localhost.localdomain
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'lib/debugobjects.c')
0 files changed, 0 insertions, 0 deletions