aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-sqlite.py
diff options
context:
space:
mode:
authorPeter Zijlstra <[email protected]>2019-05-01 15:11:17 +0200
committerSteven Rostedt (VMware) <[email protected]>2019-05-08 12:14:37 -0400
commit4b33dadf37666c0860b88f9e52a16d07bf6d0b03 (patch)
treee4280e5ee2394d59855aa2ac528911182aa2b221 /tools/perf/scripts/python/export-to-sqlite.py
parent2700fefdb2d9751c416ad56897e27d41e409324a (diff)
x86_64: Allow breakpoints to emulate call instructions
In order to allow breakpoints to emulate call instructions, they need to push the return address onto the stack. The x86_64 int3 handler adds a small gap to allow the stack to grow some. Use this gap to add the return address to be able to emulate a call instruction at the breakpoint location. These helper functions are added: int3_emulate_jmp(): changes the location of the regs->ip to return there. (The next two are only for x86_64) int3_emulate_push(): to push the address onto the gap in the stack int3_emulate_call(): push the return address and change regs->ip Cc: Andy Lutomirski <[email protected]> Cc: Nicolai Stange <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: "H. Peter Anvin" <[email protected]> Cc: the arch/x86 maintainers <[email protected]> Cc: Josh Poimboeuf <[email protected]> Cc: Jiri Kosina <[email protected]> Cc: Miroslav Benes <[email protected]> Cc: Petr Mladek <[email protected]> Cc: Joe Lawrence <[email protected]> Cc: Shuah Khan <[email protected]> Cc: Konrad Rzeszutek Wilk <[email protected]> Cc: Tim Chen <[email protected]> Cc: Sebastian Andrzej Siewior <[email protected]> Cc: Mimi Zohar <[email protected]> Cc: Juergen Gross <[email protected]> Cc: Nick Desaulniers <[email protected]> Cc: Nayna Jain <[email protected]> Cc: Masahiro Yamada <[email protected]> Cc: Joerg Roedel <[email protected]> Cc: "open list:KERNEL SELFTEST FRAMEWORK" <[email protected]> Cc: [email protected] Fixes: b700e7f03df5 ("livepatch: kernel: add support for live patching") Tested-by: Nicolai Stange <[email protected]> Reviewed-by: Nicolai Stange <[email protected]> Reviewed-by: Masami Hiramatsu <[email protected]> Signed-off-by: Peter Zijlstra (Intel) <[email protected]> [ Modified to only work for x86_64 and added comment to int3_emulate_push() ] Signed-off-by: Steven Rostedt (VMware) <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions