| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
* runtime/uprobes2/uprobes.c (uprobe_get_pc_task): new function
(lookup_uretprobe): new helper function
(uprobe_get_pc): use it
* runtime/uprobes2/uprobes.h (uprobe_get_pc_task): declare
* runtime/uprobes/uprobes.c : ditto
* runtime/uprobes/uprobes.h : ditto
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This implements proper unwinding from uprobes in the presence of
uretprobe trampolines.
* runtime/stack.c (_stp_stack_print): Rework for uprobe context case
and refactor a bit.
* runtime/uprobes2/uprobes.h (GET_PC_URETPROBE_NONE): new constant
* runtime/uprobes2/uprobes.c (uprobe_get_pc): Support translating the
trampoline function from uprobe context in addition to uretprobe
context.
* runtime/uprobes/uprobes.h (GET_PC_URETPROBE_NONE): ditto
* runtime/uprobes/uprobes.c (uprobe_get_pc): ditto
* tapsets.cxx (uprobe_derived_probe_group::emit_module_decls):
Initialize ri in context to GET_PC_URETPROBE_NONE in generated
enter_uprobe_probe.
* testsuite/systemtap.context/fib.stp: Add an option to do a backtrace
on function entry.
* testsuite/systemtap.context/fib.exp: Test backtrace in function
entry (uprobe) probes.
|
|
|
|
| |
* runtime/uprobes/uprobes.c (uprobe_get_pc): new function
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
uprobe_fork_uproc() runs with parent_uproc->rwsem locked.
However uprobe_mk_process() that gets called within uprobe_fork_uproc()
also locks child_uproc->rwsem after initializing it.
Lockdep report confuses this to acquiring a lock that already has been
acquired and suggests using sub-classes.
The alternatives we have are:
1. use classes level to distinguish different uproc structures.
2. unlock parent_uproc->rwsem before we call uprobe_fork_uproc().
3. dont try locking child_uproc->rwsem; since we are protected by
uproc_mutex as well as parent_uproc->rwsem;
We use the last approach.
Signed-off-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
---
|
|
|
|
|
| |
For uprobes 1 and 2, add unmap_u[ret]probe() and define UPROBES_API_VERSION=2.
Adapt tapsets.cxx accordingly.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Fix handling of fork with uretprobe_instances outstanding.
Add regression test.
|
|
|
|
|
|
|
| |
* runtime/uprobes/uprobes.c: Intercept handler-destined
signals received while we're single-stepping, and re-queue
them afterward.
* runtime/uprobes/uprobes.h: Ditto
|
|
|
|
|
|
|
| |
calls to access_process_vm() when populating instructions
slots. Fixes an SMP bug on multithreaded apps with many
active probepoints.
* runtime/uprobes/uprobes.h: Ditto
|
|
|
|
| |
rcu_dereferences of engine->data to resync with kernel.org builds.
|
|
|
|
| |
access_process_vm(), for kernels that don't export it.
|
| |
|
|
|
|
|
|
|
|
|
| |
uprobes_ppc64.h, uprobes_s390.h: Adjusted SLOT_IP and
arch_validate_probed_insn to accept task pointer (needed by
x86_64); added uprobe_probept_arch_info and uprobe_task_arch_info
(ditto).
* runtime/uprobes/uprobes_i386.c: Fixed a couple of glitches
discovered when porting to x86_64
|
|
|
|
|
|
|
| |
* runtime/uprobes/uprobes.c: Adjust module ref-count
when creating or removing uprobe_process, so "rmmod
--wait uprobes" waits as needed until uretprobed
functions return.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* main.cxx: Add pass 4.5: make uprobes.ko in runtime/uprobes
* buildrun.cxx: Add uprobes_enabled() and make_uprobes().
Factor run_make_cmd() out of compile_pass().
* buildrun.h: Add uprobes_enabled and make_uprobes decls.
* tapsets.cxx: Do correct #include for modprobed uprobes.ko;
set need_uprobes in pass 2.
* session.h: Add need_uprobes
* runtime/staprun/common.c: Add -u option -> need_uprobes
* runtime/staprun/staprun_funcs.c: Generalize insert_module()
to support inserting uprobes.ko.
* runtime/staprun/staprun.c: Add enable_uprobes(). insert_module
call becomes insert_stap_module().
* runtime/staprun/staprun.h: Reflect insert_module() and
need_uprobes changes
* runtime/uprobes/*.[c,h]: uprobes is built as a module,
rather than included into the source of the stap-generated
module.
* runtime/uprobes/Makefile: Added
|
|
uprobes_i386.c, uprobes_i386.h: i386 code
uprobes_arch.c, uprobes_arch.h: map to architecture-specific files
|