summaryrefslogtreecommitdiffstats
path: root/tapset
Commit message (Collapse)AuthorAgeFilesLines
* Add $arch/nd_syscalls.stpJosh Stone2009-06-025-0/+1419
| | | | | These are all the dwarfless analogs to $arch/syscalls.stp. (Only i686 and x86_64 have been tested...)
* Clean up the formatting of $arch/syscalls.stpJosh Stone2009-06-025-149/+224
|
* Complete a few TODO probe points in nd_syscalls2Josh Stone2009-06-021-39/+96
| | | | This adds renameat, unlinkat, unshare, and compat_sys_semctl.
* Fix nd_syscall2 open.return typo.Mark Wielaard2009-06-021-2/+2
| | | | | * tapset/nd_syscalls2.stp (nd_syscall.open.return): Add commas after alternatives.
* More nd_syscalls2 cleanup, and add SYSCALL_WRAPPERSJosh Stone2009-06-021-291/+575
| | | | | | | - Fix a few more formatting issues - Add SYSCALL_WRAPPERS analogous to 132c33 tapset/syscalls2.stp Thanks to Przemysław Pawełczyk for the helpful translation scripts.
* Fix a few variables in nd_syscalls2Josh Stone2009-05-291-13/+13
|
* Clean up nd_syscalls2 formattingJosh Stone2009-05-291-556/+786
| | | | This applies some of the formatting rules specified in c0c1ccc.
* Kill trailing whitespace in nd_syscalls[2]Josh Stone2009-05-292-144/+144
|
* Convert nd_syscalls2 to kprobe.functionJosh Stone2009-05-291-437/+437
|
* Create nd_syscalls2.stpJoeLynn Keniston2009-05-291-0/+3916
| | | | | | | This contains an initial transformation of syscalls2.stp to start using numbered parameter access instead of relying on dwarf. Signed-off-by: Josh Stone <jistone@redhat.com>
* Add ucontext-symbols and ucontext-unwind tapset functions to the manual.Mark Wielaard2009-05-281-1/+0
| | | | | | | * tapset/ucontext-unwind.stp (ubacktrace): Remove empty line before function triggering parse errors for doc scanner. * doc/SystemTap_Tapset_Reference/tapsets.tmpl (chapter context_stp): Add tapset/ucontext-symbols.stp and tapset/ucontext-unwind.stp.
* Fix nd_syscalls.stp for architectures using SYSCALL_WRAPPERS.Przemyslaw Pawelczyk2009-05-261-305/+568
| | | | | | | | | | | | Add kprobe.function("SyS_*") probe points to nd_syscall.* probe aliases. Analogue of commit 132c337c with two exceptions: - remove sufficiency of these new probe points (use '?' instead of '!'), because translator always considers them resolved, - make non-SyS probe points optional in probe aliases affected by syscall wrappers, because otherwise they will fail on such architectures. Signed-off-by: Josh Stone <jistone@redhat.com>
* Move the "pure" tag into the body of __is_user_regsJosh Stone2009-05-222-2/+4
| | | | | | The "/* pure */" tag has no effect unless it is within the embedded-C body of a function. In this instance, they were accidentally moved out during the syscall cleanups.
* Use embedded-C for empty functionsJosh Stone2009-05-223-12/+6
| | | | | | | | | | The functions asmlinkage() and fastcall() are used to help access syscall parameters on i686. All other archs don't need this, but they still define empty functions to shield the callers from arch details. However, stap issues warnings for empty script-level functions. This patch changes them to "%{ /* pure */ %}" so there's no complaint, and they will still get optimized away.
* Uncomment 'name' variable in nd_syscall.lseek probe point.Przemyslaw Pawelczyk2009-05-221-1/+1
| | | | Signed-off-by: Josh Stone <jistone@redhat.com>
* Add missing probe points in nd_syscalls.stp.Przemyslaw Pawelczyk2009-05-221-0/+154
| | | | | | | | Add probe points for faccessat, fchmodat, fchownat, linkat and mknodat. Analogue of commits: a3d153e5, 335972be, 46e2c2c1, c815c982, dac6e242 and bad69f1d. Signed-off-by: Josh Stone <jistone@redhat.com>
* Remove return probes for exit[_group] in nd_syscalls.stp.Przemyslaw Pawelczyk2009-05-221-3/+4
| | | | | | Analogue of commit 39a8b0bc. Signed-off-by: Josh Stone <jistone@redhat.com>
* Unify formatting of nd_syscalls.stp.Przemyslaw Pawelczyk2009-05-221-110/+103
| | | | | | Rules were already specified in commit c0c1ccc6. Signed-off-by: Josh Stone <jistone@redhat.com>
* PR10177: init/kill time in sleepy context onlyJosh Stone2009-05-201-15/+2
| | | | | | | | | | | | Previously, _stp_init_time and _stp_kill_time were being called from begin/end/error probes, which will run with preemption disabled. The BUG reported on RT kernels showed that cpufreq_unregister_notifier can end up sleeping, which violates our preemption block. This patch moves the init/kill into systemtap_module_init/exit, where it is safe to sleep. The code maintains a new predicate with the define STAP_NEED_GETTIMEOFDAY, so we don't still incur any timer overhead if it's not used.
* Adapt sid to latest kernelWenji Huang2009-05-191-0/+4
|
* Fix alignment of probe aliases in syscalls(|2).stp.Przemyslaw Pawelczyk2009-05-192-736/+736
| | | | | | | Align probe points in probe aliases to equal sign using spaces as it's already done in nd_syscalls.stp. Signed-off-by: Josh Stone <jistone@redhat.com>
* Unify formatting of syscalls.stp and syscalls2.stp.Przemyslaw Pawelczyk2009-05-192-1059/+1407
| | | | | | | | | | | | | | | Rules: - Specify probe points for aliases starting from the alias declaration line and with one probe point per line. - Use K&R indent style -- probe alias/point/function opening brace goes to the line following the declaration, other opening braces are kept on the same line as the control statements. - Indent using tabs. - Surround operators with spaces. - Put spaces after commas. - Avoid trailing whitespaces. Signed-off-by: Josh Stone <jistone@redhat.com>
* Correct misnamed variables in syscalls.stp.Przemyslaw Pawelczyk2009-05-191-33/+27
| | | | | | | Rename variables accordingly to argument names used in man pages in syscall.(faccess|fchmod|fchown|link|mknod)at probe points. Signed-off-by: Josh Stone <jistone@redhat.com>
* Complete the names-to-numbers conversion in nd_syscalls.stp.Przemyslaw Pawelczyk2009-05-181-980/+1711
| | | | | | | | Replace in-scope variables references with *_arg functions. Use 'kprobe' family of probes instead of 'kernel' family for dwarfless probing. Also fix a few typos and unify formatting. Signed-off-by: Josh Stone <jistone@redhat.com>
* Fix typo in mq_timedreceive probe point.Przemyslaw Pawelczyk2009-05-181-1/+1
| | | | * tapset/syscalls.stp: Rename abs_timout_uaddr to abs_timeout_uaddr.
* Fix inconsistent indentation for including header file in aux_syscalls.stp.Sunzen Wang2009-05-141-4/+4
| | | | * tapset/aux_syscalls.stp: Don't indent #include <linux/utime.h>.
* Implement caller:string() in terms of symname() and caller_addr().Mark Wielaard2009-05-131-8/+5
| | | | | * tapset/context-unwind.stp (caller): Implement as stap function using symname(), caller_addr() and sprintf().
* context tapset: sid() function to return task session leader pidMalte Nuhn2009-05-081-0/+12
|
* Fixed uaddr tapset function for ppc64 by adding task_pt_regs() definition.David Smith2009-04-301-0/+6
| | | | | | PR10117 fix. * tapset/context.stp: Added ppc64 task_pt_regs() definition if it dooesn't already exist.
* PR10007: Avoid probing syscall entry points in the testsuite.Ananth N Mavinakayanahalli2009-04-301-10/+14
| | | | While there, fix minor issues with the s390x syscall tapset.
* Make sure user_string_n() results are always zero terminated strings.Mark Wielaard2009-04-281-1/+4
| | | | | | * tapset/conversions.stp (user_string_n2): Explicitly null terminate return string. (user_string_n_warn): Likewise.
* Add function of returning the char in given position of stringWenji Huang2009-04-261-0/+12
| | | | | | * tapset/string.stp: New function stringat. * testsuite/systemtap.printf/char1.exp: Update test case. * testsuite/systemtap.printf/char1.stp: Ditto.
* Correct fd variable name in fadvise64 probe points.Przemyslaw Pawelczyk2009-04-251-4/+4
| | | | * tapset/syscalls.stp: Rename fs variable to fd.
* Mark uaddr tapset function as EXPERIMENTAL.Mark Wielaard2009-04-231-2/+4
| | | | | * tapset/context.stp (uaddr): Marked as experimental. Add FIXME for vdso tracking bug #10080.
* Mark ucontext tapset functions EXPERIMENTAL.Mark Wielaard2009-04-212-5/+5
| | | | | | * tapset/ucontext-symbols.stp (usymname, usymdata, print_ustack): mark EXPERIMENTAL. * tapset/ucontext-unwind.stp (print_ubacktrace, ubacktrace): Likewise.
* Add ubacktrace(), print_ustack() and print_ubacktrace().Mark Wielaard2009-04-212-0/+75
| | | | | | | | * runtime/sym.c (_stp_usymbol_print): New function. * tapset/ucontext-unwind.stp (print_ubacktrace): New tapset function. (ubacktrace): Likewise. * tapset/ucontext-symbols.stp (print_ustack): Likewise. * testsuite/buildok/ustack.stp: New test for above three functions.
* Remove documentation weirdness FIXME in tapset print_stack().Mark Wielaard2009-04-211-2/+2
| | | | | | Weirdness was fixed in commit d4db5608. * tapset/context-symbols.stp (print_stack): Remove FIXME.
* Pass task from tapset, through stack and unwind functions for lookup.Mark Wielaard2009-04-201-2/+2
| | | | | | | | | | | | | | | | | * runtime/stack-arm.c (__stp_stack_print): Take struct task_struct *. * runtime/stack-ia64.c (__stp_stack_print): Likewise. * runtime/stack-ppc64.c (__stp_stack_print): Likewise. * runtime/stack-s390.c (__stp_stack_print): Likewise. * runtime/stack-i386.c (__stp_stack_print): Likewise. And add check and pass to unwind() and _stp_func_print(). * runtime/stack-x86_64.c: Likewise. * runtime/stack.c *_stp_stack_print): Take and pass on task_struct. (_stp_stack_snprint): Likewise. * runtime/unwind.c (unwind): Take and use task_struct for _stp_mod_sec_lookup(). * tapset/context-unwind.stp (print_backtrace): Pass NULL to _stp_stack_print(). (backtrace): Pass NULL to _stp_stack_snprint().
* Avoid sign extension in syscall return values.David Smith2009-04-171-9/+15
| | | | | | | | 2009-04-17 David Smith <dsmith@redhat.com> * tapset/utrace.stp: Cast the return value of syscall_get_return_value() to an unsigned long to avoid sign extension.
* PR9953: split up the two process.* tapsetsJosh Stone2009-04-142-18/+18
| | | | | | | The overlapping process.* tapsets are now separated. Those probe points documented in stapprobes(3stap) remain the same. Those that were formerly in stapprobes.process(3stap) have been renamed to kprocess, to reflect their kernel perspective on processes.
* Add new TCP and IP functionsAndre Detsch2009-04-142-0/+140
| | | | | | | | | | | | | | | | | | | This patch adds some basic functions to the IP and TCP tapsets. Mainly, it's possible to get the iphdr and tcphdr from a sk_buff structure. As a consequence, a TCP probe called tcp.receive() was created and is probed every time a TCP packet is received, and a lot of useful fields is available, as the TCP flags. Also a small example that works like tcpdump for received TCP packets was created. This patch was tested on x86 and ppc machines, on 2.6.18 kernel and also on mainline one. Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com> Signed-off-by: Andre Detsch <adetsch@br.ibm.com> Signed-off-by: Josh Stone <jistone@redhat.com>
* Uses <asm/syscall.h> when available.David Smith2009-04-091-3/+5
| | | | | | | | | | | | | | | | | | | | 2009-04-09 David Smith <dsmith@redhat.com> * buildrun.cxx (compile_pass): Compile autoconf test for <asm/syscall.h>. * runtime/autoconf-asm-syscall.c: New "autoconf" test the presence of <asm/syscall.h>. * runtime/syscall.h: If <asm/syscall.h> exists, use it. Otherwise, use our private copy of the functions for each architecture. (syscall_get_nr): Renamed from __stp_user_syscall_nr(). (syscall_get_return_value): Renamed from __stp_user_syscall_return_value(). (syscall_get_arguments): Renamed from __stp_user_syscall_arg(). * runtime/task_finder.c (__stp_utrace_task_finder_target_syscall_exit): Uses new syscall.h functions. * tapset/utrace.stp: Ditto.
* Add uaddr() context tapset function.Mark Wielaard2009-04-081-0/+25
| | | | | * tapset/context.stp (uaddr): New sfunction. * testsuite/buildok/uaddr.stp: New test.
* Create usymname and usymdata variant that trigger STP_NEED_VMA_TRACKER.Mark Wielaard2009-04-072-2/+54
| | | | | | | | | * tapset/context-symbols.stp (syname, symdata): Pass NULL for kernel address. * tapset/ucontext-symbols.stp: New file defining usymname and usymdata. * testsuite/systemtap.context/usymbols.exp: Use usymname, remove STP_NEED_VMA_TRACKER hack. * testsuite/buildok/usymdata.stp: New test. * testsuite/buildok/usymname.stp: Likewise.
* New ANSI escape sequences tapsetEugene Teo2009-04-031-0/+70
| | | | | | | This adds a new tapset for ANSI escape sequences. It is based on an existing tapset that was written by Masami Hiramatsu for the stapgames project. This also adds a version of ansi_color.stp script that displays other attributes other than the bold effect.
* Improvements to errno tapsetEugene Teo2009-04-031-3/+11
| | | | | | This adds an errno_p() function that will return an absolute errno if it is valid, or zero if it is not. It also simplifies the if statement in the errno_str() function.
* PR6580: Implement symname, symdata and modname context functions.Mark Wielaard2009-04-022-8/+54
| | | | | | | | | | | | | | | | | | This adds a couple of the suggested context/stack revamp functions from PR6580. In particular it replaces the symbolname() function that sneaked in with the pr6866 branch merge with the suggested symname(). * runtime/sym.c (_stp_mod_sec_lookup): Make section optional. (_stp_symbol_snprint): Provide a way to get optional module info. * tapset/context-symbols.stp: Replace symbolname() with symname(), add modname() and symdata(). (probemod): Implement pc based fallback. * tapset/context-unwind.stp (caller): Adjust for _stp_symbol_snprint change. * testsuite/systemtap.context/usymbols.exp: Use new symname. * testsuite/buildok/modname.stp: New test. * testsuite/buildok/symdata.stp: Likewise. * testsuite/buildok/symname.stp: Likewise.
* Merge branch 'master' of ssh://sources.redhat.com/git/systemtapMark Wielaard2009-04-011-1/+1
|\
| * PR10020 sys_sigaltstack param changeFrank Ch. Eigler2009-04-011-1/+1
| | | | | | | | | | | | The new code uses a %( kernel_v < "2.6.29" %) conditional to look at the passed pt_regs instead of named *bx parameters. A more general solution will be needed at some point.
* | Merge branch 'master' into pr6866Mark Wielaard2009-04-013-19/+40
|\|