diff options
Diffstat (limited to 'tapset')
-rw-r--r-- | tapset/aux_syscalls.stp | 8 | ||||
-rw-r--r-- | tapset/context-unwind.stp | 13 |
2 files changed, 9 insertions, 12 deletions
diff --git a/tapset/aux_syscalls.stp b/tapset/aux_syscalls.stp index 009b0532..9cb7a3df 100644 --- a/tapset/aux_syscalls.stp +++ b/tapset/aux_syscalls.stp @@ -60,10 +60,10 @@ function _struct_timezone_u:string(uaddr:long) %} %{ - // Needed for the following four functions - // _struct_utimbuf_actime, _struct_utimbuf_modtime, - // _struct_compat_utimbuf_actime, _struct_compat_utimbuf_modtime - #include <linux/utime.h> +// Needed for the following four functions +// _struct_utimbuf_actime, _struct_utimbuf_modtime, +// _struct_compat_utimbuf_actime, _struct_compat_utimbuf_modtime +#include <linux/utime.h> %} // Returns the value of the actime field of a utimbuf in user space diff --git a/tapset/context-unwind.stp b/tapset/context-unwind.stp index f1e99dc8..d6654d25 100644 --- a/tapset/context-unwind.stp +++ b/tapset/context-unwind.stp @@ -51,16 +51,13 @@ function backtrace:string () %{ /* pure */ * sfunction caller - Return name and address of calling function * * Return the address and name of the calling function. + * This is equivalent to calling: + * sprintf("%s 0x%x", symname(caller_addr(), caller_addr())) * <emphasis>Works only for return probes at this time.</emphasis> */ -function caller:string() %{ /* pure */ - if (CONTEXT->pi) - _stp_symbol_snprint( THIS->__retvalue, MAXSTRINGLEN, - (unsigned long)_stp_ret_addr_r(CONTEXT->pi), - current, 0); - else - strlcpy(THIS->__retvalue,"unknown",MAXSTRINGLEN); -%} +function caller:string() { + return sprintf("%s 0x%x", symname(caller_addr()), caller_addr()); +} /** * sfunction caller_addr - Return caller address |