mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
x86: ptrace: Add function argument access API
Add regs_get_argument() which returns N th argument of the function call. Note that this chooses most probably assignment, in some case it can be incorrect (e.g. passing data structure or floating point etc.) This is expected to be called from kprobes or ftrace with regs where the top of stack is the return address. Link: http://lkml.kernel.org/r/152465885737.26224.2822487520472783854.stgit@devbox Signed-off-by: Masami Hiramatsu <[email protected]> Signed-off-by: Steven Rostedt (VMware) <[email protected]>
This commit is contained in:
parent
40b53b7718
commit
3c88ee194c
3 changed files with 46 additions and 0 deletions
|
|
@ -290,6 +290,13 @@ config HAVE_RSEQ
|
|||
This symbol should be selected by an architecture if it
|
||||
supports an implementation of restartable sequences.
|
||||
|
||||
config HAVE_FUNCTION_ARG_ACCESS_API
|
||||
bool
|
||||
help
|
||||
This symbol should be selected by an architecure if it supports
|
||||
the API needed to access function arguments from pt_regs,
|
||||
declared in asm/ptrace.h
|
||||
|
||||
config HAVE_CLK
|
||||
bool
|
||||
help
|
||||
|
|
|
|||
Loading…
Reference in a new issue