| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
| |
* tapset/inet_sock.stp : Add prefix "inet_" to field.
* tapset/ip.stp : Ditto.
* tapset/tcp.stp : Ditto.
* tapset/tcpmib.stp : Ditto.
|
|
|
|
| |
that got left out in earlier commit 0c487e433fd6343e49b1e9dbc6492f38cfe26143.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* runtime/task_finder_vma.c (stap_remove_vma_map_info): Return negative
status on failure.
(stap_find_vma_map_info): Likewise.
(stap_find_vma_map_info_user): New function.
(stap_drop_vma_maps): New function.
* runtime/sym.h (addr): Renamed to static_addr, to store addresses for
sections which are always mapped at the same address.
(_stp_module_relocate): Add extra struct task_struct *tsk argument.
* runtime/sym.c (_stp_tf_exec_cb): New callback, calls stap_drop_vma_maps.
(_stp_tf_mmap_cb): Don't store address in module.section, but call
stap_add_vma_map_info() per tsk->group_leader for matched module.
Don't register empty/null modules.
(_stp_module_relocate): Take extra struct task_struct *tsk argument,
cache last tsk used. Only use section->static_addr for none dynamic
modules. Use stap_find_vma_map_info_user() to locate dynamic modules.
(_stp_mod_sec_lookup): Add extra argument unsigned long *rel_addr to
optionally store relative address when module/section found.
(_stp_kallsyms_lookup): Use _stp_mod_sec_lookup to find relative address.
(_stp_sym_init): Register _stp_tf_exec_cb in stap_task_finder_target.
Add error check to see if task finder could be initialized.
* dwflpp.cxx (emit_address): Pass NULL for kernel/modules and current for
user tasks to _stp_module_relocate.
* runtime/transport/symbols.c (_stp_do_relocation): Set new static_addr
_stp_section field.
* runtime/unwind.c (adjustStartLoc): Take new struct task_struct *tsk
argument and pass to stap_find_vma_map_info_user and _stp_module_relocate
to find adjusted addr.
(_stp_search_unwind_hdr): Pass through struct task_struct *tsk.
(unwind_frame): Likewise.
* tapset/context-symbols.stp (probemod): Add NULL to _stp_mod_sec_lookup
call to indicate we aren't interested in relative address.
* tapsets.cxx (dwarf_derived_probe_group::emit_module_init): Pass NULL to
_stp_module_relocate to indicate kernel/module address.
|
|
|
|
|
|
| |
The automatic documentation extraction doesn't allow blank lines between the
the comment and the actual code. Removed the problem blank line to allow
the information to be extracted for the SystemTap Tapset Reference Manual.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This only prints symbol+offset, or an address if the symbol isn't
known.
* runtime/runtime.h (SYM_VERBOSE_NO, SYM_VERBOSE_FULL,
SYM_VERBOSE_BRIEF): new constants
* runtime/stack.c (_stp_stack_print): support brief format
* runtime/sym.c (_stp_func_print): ditto
* tapset/ucontext-unwind.stp (print_ubacktrace_brief): new function
* testsuite/systemtap.context/fib.c: new test program
* testsuite/systemtap.context/fib.stp: new test
* testsuite/systemtap.context/fib.exp: new test
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It's easily available in kretprobes and uretprobes and is consistent
with the rest of the program state.
* translate.cxx (emit_common_header) : add uretprobe_instance to context.
* tapsets.cxx (common_probe_entryfn_prologue): Initialize ri in
context to 0.
(dwarf_derived_probe_group::emit_module_decls): Change IP to return
address in kretprobes.
(uprobe_derived_probe_group::emit_module_decls): enter_uretprobe_probe:
set ri (uretprobe_instance) in context. Change IP to return
address in uretprobes. Don't emit uprobe include and #define
* runtime/runtime.h : Add includes and #define for uprobes.
* runtime/stack.c (_stp_stack_print, _stp_stack_snprint): Add extra
argument for uretprobe_instance.
* tapset/context-unwind.stp (print_backtrace, backtrace): Pass NULL
for uretprobe_instance to _stp_stack_print.
* tapset/ucontext-unwind.stp (print_ubacktrace, ubacktrace): pass
uretprobe_instance to _stp_stack_print
* testsuite/systemtap.context/uprobe_uaddr.exp : new test for uaddr in
function probes
* testsuite/systemtap.context/uprobe_uaddr.stp : new file
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* tapset/ioscheduler.stp : Make probe optional.
* tapset/irq.stp : Ditto.
* tapset/scheduler.stp : Ditto.
* tapset/tcpmib.stp : Ditto.
* tapset/linuxmib.stp : Switch variable by version.
* tapset/tty.stp : Ditto.
* testsuite/buildok/irq.stp : Make probe test optional.
* testsuite/buildok/tty.stp : Ditto.
* testsuite/systemtap.examples/network/netdev.stp : Ditto.
* testsuite/buildok/tcpmib-all-probes.stp : Add embedded functions.
|
|
|
|
|
|
|
|
|
|
| |
* runtime/copy.c: Can use ppc64's code.
* runtime/regs.h: Ditto.
* runtime/string.h: Ditto.
* tapset/context.stp: Ditto.
* tapset/errno.stp: Ditto.
Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
|
|
|
|
|
|
|
| |
* tapset/nd_syscalls.stp: Implement ppc32 variant of __is_user_regs.
* tapset/syscalls.stp: Ditto.
Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
|
|
|
|
|
|
| |
* doc/SystemTap_Tapset_Reference/tapsets.tmpl: Add string.stp chapter.
* tapset/string.stp: Convert documentation to standard markup and add
documentation that was missing.
|
|
|
|
|
| |
* tapset/scheduler.stp (__scheduler.kthread_stop.kp): Change
priority to prio.
|
|
|
|
|
|
|
| |
* doc/SystemTap_Tapset_Reference/Makefile.am: Check for file existence
before doing compare.
* doc/SystemTap_Tapset_Reference/Makefile.in: Regenerated.
* tapset/ioblock.stp: Fixed comment so that docs can be built.
|
| |
|
|
|
|
|
|
| |
* tapset/ioblock.stp: Update comment and variables.
* testsuite/buildok/ioblock_test.stp: Add parameters.
* testsuite/buildok/ioscheduler.stp: Remove redundant parameters.
|
|
|
|
|
| |
Added testcases for these probes.
Also, modified comments in ioblock.stp so that tapset docmentation can be automatically generated for this tapset.
|
|
|
|
|
|
|
| |
* tapset/networking.stp: Made 'netdev.change_rx_flag' and
'netdev.get_stats' optional, since those functions don't exist on
RHEL5.
* testsuite/buildok/netdev.stp: Ditto.
|
|
|
|
|
|
|
| |
* tapset/nfs_proc.stp: Made 'nfs.proc.read', 'nfs.proc.write', and
'nfs.proc.commit' optional for newer kernels without those functions.
* testsuite/systemtap.pass1-4/buildok.exp: Expect nfs-all-probes.stp to
pass.
|
| |
|
|
|
|
|
| |
* tapset/aux_syscalls.stp: Only define entries for IRQF_* flags if they
exist.
|
|
|
|
|
| |
* tapset/aux_syscalls.stp: Only define entries for
IRQF_NOBALANCING/IRQF_IRQPOLL if they exist.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* tapset/nfs.stp(nfs.fop.fsync): Added support for nfs_file_fsync.
(nfs.fop.fsync.return): Ditto.
(nfs.aop.readpages.return): Fixed 'size' bug.
(nfs.aop.write_begin): Renamed to make 'nfs.*.*' probes work correctly.
(nfs.aop.write_end): Ditto.
(__nfs.aop.write_begin): Ditto.
(__nfs.aop.write_end): Ditto.
(__nfs.aop.prepare_write): Ditto.
(__nfs.aop.commit_write): Ditto.
(nfs.fop.aio_read.return): Always sets 'units'.
(nfs.fop.aio_write.return): Ditto.
(nfs.fop.sendfile.return): Ditto.
|
|
|
|
|
| |
* tapset/nfs.stp: Added support for nfs_write_begin()/nfs_write_end(),
which replaced nfs_prepare_write()/nfs_commit_write().
|
|
|
|
|
| |
* tapset/ansi.stp: Add documentation for every function.
* doc/SystemTap_Tapset_Reference/tapsets.tmpl: Add chapter on ansi.
|
|
|
|
|
|
|
| |
IRQF_ONESHOT was only introduced in 2.6.32. It doesn't hurt defining it
if it isn't already there. It will just never show up on older kernels.
* tapset/aux_syscalls.stp: Define IRQF_ONESHOT if not already defined.
|
| |
|
|
|
|
|
| |
* doc/SystemTap_Tapset_Reference/tapsets.tmpl: Add chapter on ctime.stp.
* tapset/ctime.stp: Turn documentation into proper reference markup.
|
|
|
|
|
| |
* doc/SystemTap_Tapset_Reference/tapsets.tmpl: Add conversions.stp chapter.
* tapset/conversions.stp: Add documentation for all functions.
|
|
|
|
|
| |
* tapset/ucontext-symbols.stp (usymname): Add assert_is_myproc() and mark
as unprivileged, just like usymdata().
|
|
|
|
|
| |
It references the file include/linux/if_ether.h as the one that contains
the protocol numbers and types.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since 2.6.25, kretprobes can carry a data packet to be filled in an
entry_handler. This patch lets us store our implicitly-saved $target
variables in .return probes in that data area.
* tapset/kretprobe.stp: New get/set functions for kretprobe data.
* translate.cxx (c_unparser::emit_common_header): Add context->pi_longs.
* tapsets.cxx
(dwarf_var_expanding_visitor::visit_target_symbol_saved_return): Switch
between the old and new methods of saving $vars in .return probes.
(dwarf_var_expanding_visitor::gen_mapped_saved_return): The old way.
(dwarf_var_expanding_visitor::gen_kretprobe_saved_return): The new way.
(dwarf_derived_probe::join_group): Don't register paired entry-handlers.
(dwarf_derived_probe::dwarf_derived_probe): Remember saved-var details.
(dwarf_derived_probe_group::emit_module_decls): Output saved-var details.
Also split the kretprobe handler whether we're on entry or return.
(dwarf_derived_probe_group::emit_module_init): Prepare the entry handler.
* testsuite/systemtap.base/kretprobe-vars.stp: Test implicit $var saving.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
* tapset/aux_syscalls.stp(_sock_type_str): Rewrote in embedded-C and added
socket flags support.
(_sock_flags_str): New function.
* tapset/syscalls.stp: syscall.accept prefers to use sys_accept4 when it
exists. Added support for sys_accept4's 'flag' parameter.
* testsuite/systemtap.syscall/net1.c (main): Updated regular expression to
handle the new 'flags' argument.
|
|
|
|
|
|
| |
A new tapset that supports tty devices and consequently serial
devices. It is just a basic implementation that can be extended
as demands appears
|
|
|
|
|
| |
* tapset/task.stp: Use @cast(...,"task_struct","kernel<linux/sched.h")
throughout to operate dwarf-free.
|
|
|
|
|
|
|
|
| |
Use proper $vars according to CONFIG_NFSD and CONFIG_COMPAT in
syscall.nfsservctl and mask it out along with return probe if
CONFIG_NFSD != "[ym]" && CONFIG_COMPAT != "y".
* tapset/syscalls2.stp (syscall.nfsservctl): Fix it.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Inline functions do not have an indentifiable return point and require
kernel built using VTA-enabled gcc to get tracking of variables. OTOH
syscall functions are very rarely inlined (depending on the compiler
mood), therefore filtering probes to include only non-inlined functions
ensures consistent behavior between different kernels.
This removes the problem of inaccessible variables in inlined syscalls
that is described in comments #6-9 to PR5890 and gives us the status quo
w.r.t. syscall probing, because before the commit solving PR10572
(b7478964) inline instances were masked anyway by non-inline ones.
You can check whether you have inlined syscalls using following command:
$ stap -l 'kernel.function("sys_*"),kernel.function("compat_sys_*")' \
2>&1 -vvv | awk '/^selected inline/{print $5}'
* tapset/syscalls.stp: Add .call to all entry probes.
* tapset/syscalls2.stp: Ditto.
|
|
|
|
|
|
|
| |
* tapset/task_time.stp: New tapset.
* testsuite/buildok/task_test.stp: Add new task_time functions.
* doc/SystemTap_Tapset_Reference/tapsets.tmpl: Add new section on
Task Time Tapset. Include tapset/task_time.stp.
|
| |
|
|
|
|
|
|
|
| |
* tapset/proc_mem.stp: New tapset.
* testsuite/buildok/proc_mem.stp
* doc/SystemTap_Tapset_Reference/tapsets.tmpl (memory_stp): Include
tapset/proc_mem.stp.
|
|
|
|
|
|
|
|
|
| |
This patch adds kernel tracepoints based probes to the scheduler tapset
along with the testcase, scheduler-test-tracepoints.stp and an example
script, sched_switch.stp.
Signed-off-by: Kiran Prakash <kiran@linux.vnet.ibm.com>
Signed-off-by: Josh Stone <jistone@redhat.com>
|
|
|
|
|
| |
* tapset/indent.stp (_generic_indent): Use "%-*s" instead of
string concatenation loop.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
sometimes you're probing something that is not related to
any task, as an interrupt function, and if the application
changes during the interrupt, the indentation gets confused.
For example:
0 swapper(0): -> neo_copy_data_from_queue_to_uart
69 a.out(7659): -> neo_parse_modem
74 a.out(7659): -> neo_param
14 swapper(0): <- neo_copy_data_from_queue_to_uart
83 a.out(7659): -> jsm_carrier
86 a.out(7659): <- jsm_carrier
0 swapper(0): -> neo_parse_modem
94 a.out(7659): <- jsm_tty_set_termios
8 swapper(0): <- neo_parse_modem
So, I decided to create a simpler function that doesn't
consider the task.
Much of the idea of this implementation came from Frank(Thanks)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Several problems: some invalid <command> etc. directives
in the tapset embedded docs; some analysis about the
non-generation of the pdf; some cleanup of the generated
man pages.
* configure.ac (BUILD_PDFREFDOCS): Correct condition typo, but still
leave disabled.
* doc/SystemTap_Tapset_Reference/Makefile.am (XMLTOMANPARMS): Add,
to disable noise "AUTHORS" / "COPYRIGHT" sections.
* tapset/*.stp: Removed several docbook-y markup that is not valid
in kerneldoc.
|
|
|
|
|
| |
* tapset/x86_64/nd_syscalls.stp: Switch by kernel version.
* tapset/x86_64/syscalls.stp: Ditto.
|
|
|
|
| |
* tapset/logging.stp (log): Use _stp_printf "%s\n".
|
|
|
|
|
| |
OutBcastPkts. As they are not needed for tcpipstat and tend to break
easily with kernel changes.
|
| |
|
|
|
|
|
|
|
|
|
| |
* tapset/random.stp (randint): Make it 1-arity (imply min=0).
Document with kerneldoc.
* doc/Systemtap_Tapset_Reference/tapsets.tmpl: Extract the docs.
* runtime/arith.c (_stp_random_pm_u): Rename without _pm.
(_stp_random_pm): Rewrite in terms of ..._u.
* testsuite/random.stp: Adapt & simplify.
|