| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
| |
The previous name made it easy to misread the purpose of this
field. It is only for matching executable names, not for
shared libraries.
* runtime/task_finder.c (task_finder_target): Rename field.
(*): Adjust.
* tapset-itrace.cxx, tapset-utrace.cxx, tapsets.cxx, translate.cxx: Ditto.
|
|
|
|
|
|
|
| |
* runtime/task_finder.c (non-UTRACE): Return 0 for
stap_start_task_finder.
* translate.cxx (emit_module_init): Let vma tracker
specific to utrace.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* runtime/transport/ring_buffer.c (_stp_ring_buffer_disable_cpu): New
function.
(_stp_ring_buffer_enable_cpu): Ditto.
(_stp_ring_buffer_cpu_disabled): Ditto.
(_stp_ring_buffer_empty_cpu): Only checks online cpus (instead of all
possible cpus).
(_stp_find_next_event): Ditto.
(_stp_ring_buffer_iterator_increment): Calls
_stp_ring_buffer_disable_cpu()/_stp_ring_buffer_enable_cpu() around
ring_buffer_* calls.
(_stp_ring_buffer_consume): Ditto.
(_stp_peek_next_event): Ditto.
(_stp_buffer_iter_finish): New function.
(_stp_buffer_iter_start): Ditto.
(_stp_data_read_trace): Uses
_stp_buffer_iter_start()/_stp_buffer_iter_finish().
(_stp_data_write_reserve): Checks to see if the cpu is disabled (with
_stp_ring_buffer_cpu_disabled() before reserving memory. Uses
_stp_buffer_iter_start()/_stp_buffer_iter_finish().
(_stp_transport_data_fs_init): Initializes buffer iterators.
|
|
|
|
|
|
|
| |
* translate.cxx (dump_unwindsyms): Decide based on modname[] not
mainfile[] to emit a vmcb.
* runtime/task_finder.c (non-UTRACE): Include dummy stap_{start,stop}_*
functions.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* main.cxx (main): For "-d /path" arguments, enable task finder.
* runtime/sym.h (_stp_module): Add *vmcb member.
* task_finder{.cxx,.h} (emit_vma_callback_probe_decl): Zap.
* tapset-itrace.cxx, tapset-utrace.cxx: Use unwindsyms_modules
instead.
* tapsets.cxx (uprobe::emit_module_decls): Ditto.
* translate.cxx (emit_module_init): Emit task finder registrations
for vmcb's associated with _stp_modules.
(dump_unwindsyms): Associate vmcbs with user-space unwindsyms entries.
|
|
|
|
| |
check_permissions.
|
|
|
|
| |
* runtime/staprun/staprun.c (enable_uprobes): insmod, not insert_module().
|
|
|
|
| |
certificates does not exist. It just means that the signed module is untrusted.
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* runtime/transport/ring_buffer.c (_stp_find_next_event): Works with or
without a ring_buffer iterator.
(_stp_find_next_event): Ditto.
(_stp_data_read_trace): Ifdef'ed out using ring_buffer iterators.
(_stp_get_iterator): New function.
(_stp_data_write_reserve): Calls _stp_get_iterator().
|
|\| |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
To fixup REG_IP to show the correct value after a [ku]probe trap we
assigned the address of the actual instruction pointer of the probed
instruction. That doesn't work on architectures, s390 and ia64, where
REG_IP is not a simple lvalue. Just don't try to fixup the address in
those cases. If this isn't enough, the uprobe_stmt_num.exp testcase
will point this out.
* runtime/regs.h: Define REG_IP_LVALUE for x86_64, i386, powerpc64 and arm.
* tapsets.cxx (dwarf_derived_probe_group::emit_module_decls): Only fixup
REG_IP when REG_IP_LVALUE is defined.
(uprobe_derived_probe_group::emit_module_decls): Likewise.
(kprobe_derived_probe_group::emit_module_decls): Likewise.
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* modverify.c (staprun.h): #include it.
(verify_it): Now accepts module data and signature data as arguments.
Don't open and read the signature here. Don't read the module here.
(verify_module): Now accepts module data as argument. Read the signature
once here.
* modverify.h (verify_module): Now accepts module data as argument.
* staprun.c (main): Don't call check_permissions here.
* staprun.h (check_permissions): Prototype removed.
* staprun_funcs.c (check_permissions): Now static. Accepts module data
as argument. Pass module data to check_signature.
(insert_module): Canonicalize the module path early here. Call
check_permissions here, passing it the mapped module data.
(check_signature): Now accepts module data as argument. Pass the module
data to verify_module.
(check_path): Use the already-canonicalized module path.
|
|
|
|
|
|
|
| |
* runtime/staprun/staprun_funcs.c (check_permissions): Declare
check_signature_rc outside HAVE_NSS block.
Signed-off-by: Mark Wielaard <mjw@redhat.com>
|
|\
| |
| |
| |
| |
| | |
Conflicts:
cache.cxx
|
| |\ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Setup the pt_regs REG_IP to the actual breakpoint address before
entering a probe handler for [ku]probe[ret] (and restore it after
returning). This helps getting symbol resolution and backtraces
more correct and makes it more conform with other probe handlers
like the iutrace and profile timers that also provide pt_regs
(which untill now exhibited off-by-one errors while unwinding).
* tapsets.cxx (dwarf_derived_probe_group::emit_module_decls):
Setup REG_IP correctly before calling enter_kprobe_probe
and enter_kretprobe_probe, and restore afterwards.
(uprobe_derived_probe_group::emit_module_decls): Likewise for
enter_uprobe_probe and enter_uretprobe_probe.
(kprobe_derived_probe_group::emit_module_decls): Likewise for
enter_kprobe2_probe and enter_kretprobe2_probe.
* runtime/unwind/i386.h (arch_unw_init_frame_info): Initialize
info->call_frame to zero.
* runtime/unwind/x86_64.h (arch_unw_init_frame_info): Likewise.
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* cache.cxx (add_to_cache,clean_cache): add static markers
* main.cxx (main): likewise
* runtime/staprun/common.c (send_request): likewise
* runtime/staprun/mainloop.c (stp_main_loop): likewise
* runtime/staprun/staprun.c (remove_module): likewise
* runtime/staprun/staprun.h: include sdt.h
* runtime/staprun/staprun_funcs.c (insert_module): likewise
* util.cxx (stap_system): likewise
* tapset/stap_staticmarkers.stp: new file
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* runtime/transport/ring_buffer.c (struct _stp_iterator): Renamed from
_stp_ring_buffer_data.
(_stp_data_open_trace): Uses _stp_iterator.
(_stp_data_release_trace): Ditto.
(_stp_ring_buffer_empty_cpu): Ditto.
(_stp_ring_buffer_empty): Ditto.
(_stp_ring_buffer_consume): Ditto.
(_stp_tracing_wait_pipe): Ditto.
(_stp_peek_next_event): Ditto.
(_stp_find_next_event): Ditto.
(_stp_data_read_trace): Ditto.
(_stp_data_write_reserve): Ditto.
|
|\| |
|
| |
| |
| |
| |
| |
| |
| | |
* runtime/transport/ring_buffer.c (_stp_event_to_user): Added debug prints.
(_stp_ring_buffer_consume): New function.
(_stp_find_next_event): Avoid incrementing the buffer iterator here.
(_stp_data_write_commit): Added debug prints.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* runtime/itrace.c (usr_itrace_init): Changed prototype to take a
task_struct instead of a pid.
* tapset-itrace.cxx (emit_module_decls): Updated usr_itrace_init() call.
* runtime/autoconf-find-task-pid.c: Removed, since only user_itrace_init()
was using it.
* buildrun.cxx (compile_pass): Removed autoconf-find-task-pid.c test.
|
| |
| |
| |
| | |
* sym.c (_stp_usymbol_print): Ditto.
|
| |
| |
| |
| | |
* sym.c (_stp_symbol_print): (Redundantly) initialize locals.
|
| | |
|
|\| |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* runtime/transport/ring_buffer.c (_stp_ring_buffer_empty_cpu): New function.
(_stp_ring_buffer_empty): Ditto.
(_stp_ring_buffer_iterator_increment): Ditto.
(_stp_tracing_wait_pipe): Calls _stp_ring_buffer_empty() instead of
ring_buffer_empty().
(_stp_peek_next_event): Looks at iterators first.
(_stp_find_next_event): Calls _stp_ring_buffer_empty_cpu() and
increments iterator.
(_stp_data_read_trace): Opens and closes ring_buffer iterators.
(_stp_data_poll_trace): Calls _stp_ring_buffer_empty().
(__stp_relay_wakeup_timer): Ditto.
* runtime/transport/control.c (_stp_ctl_write_cmd): Increased level
required to get a debug print.
|
|\| |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* buildrun.cxx (compile_pass): Checks for ring_buffer api change.
* runtime/autoconf-ring_buffer-flags.c: New file.
* runtime/transport/ring_buffer.c (tracing_wait_pipe): No longer
schedules, just returns. The timer function will handle it later.
(_stp_data_write_reserve): Handles ring_buffer api change. Added
overwrite processing. If we're full, delete an event to make room.
(_stp_data_write_commit): Handles ring_buffer api change.
(__stp_relay_wakeup_timer): New function.
(__stp_relay_timer_start): Ditto.
(__stp_relay_timer_stop): Ditto.
(_stp_transport_data_fs_start): Calls __stp_relay_timer_start().
(_stp_transport_data_fs_stop): Calls __stp_relay_timer_stop().
(_stp_transport_data_fs_overwrite): Sets overwrite flag.
|
|\| |
|
| |
| |
| |
| |
| |
| | |
* runtime/procfs.c (_stp_rmdir_proc_module): Now before removing either
'/proc/systemtap/${MODULE}' or '/proc/systemtap', lock the transport
directory. Also make sure '/proc/systemtap' is empty before removal.
|
|\| |
|
| |
| |
| |
| |
| |
| |
| |
| | |
* runtime/staprun/common.c (make_outfile_name): Moved from relay.c, fix not to
open /dev/null.XXX output files, and add 'bulk' argument for bulkmode.
* runtime/staprun/relay.c (make_outfile_name): Moved to common.c.
* runtime/staprun/relay_old.c (open_oldoutfile): Fix to use fopen() and store
FILE * to percpu_tmpfile[cpu].
|
| | |
|
| |
| |
| |
| |
| |
| | |
* runtime/print_old.c: Removed unneeded file.
* runtime/print_flush.c: Renamed from print_new.c
* runtime/print.c: Includes print_flush.c (instead of print_new.c).
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* runtime/transport/transport.h: Added prototype for
_stp_transport_get_state().
* runtime/transport/relay_v2.c (_stp_transport_get_state): New function.
* runtime/transport/relayfs.c (_stp_transport_get_state): Ditto.
* runtime/transport/ring_buffer.c (_stp_transport_data_fs_init): Sets
state.
(_stp_transport_data_fs_start): Ditto.
(_stp_transport_data_fs_stop): Ditto.
(_stp_transport_get_state): Returns state.
* runtime/print_new.c (stp_print_flush): Checks transport state before
trying to flush.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* runtime/transport/relay_v2.c (_stp_transport_data_fs_overwrite): Renamed
from stp_relay_set_overwrite().
* runtime/transport/relayfs.c (stp_relay_set_overwrite): Ditto.
* runtime/transport/ring_buffer.c (_stp_transport_data_fs_overwrite): New
place holder function.
* runtime/transport/transport.c (_stp_detach): Calls
_stp_transport_data_fs_overwrite().
(_stp_attach): Calls _stp_transport_data_fs_overwrite().
* runtime/transport/transport.h: Added prototype for
_stp_transport_data_fs_overwrite().
|
| |\
| | |
| | |
| | |
| | | |
Conflicts:
runtime/transport/transport.c
|
| | |
| | |
| | |
| | |
| | | |
* runtime/transport/relay_v2.c (__stp_relay_create_buf_file_callback): Set
the 'is_global' return parameter so that smp systems work correctly.
|
| |\ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | | |
* runtime/task_finder.c (__stp_call_mmap_callbacks_for_task): Fixed
cut-and-paste error.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* runtime/task_finder.c (__stp_call_mmap_callbacks_for_task): Grabs the
'mmap_sem' sempaphore. Caches vma information, releases the semaphore,
then makes mmap callbacks.
(__stp_utrace_task_finder_target_quiesce): Calls
__stp_call_mmap_callbacks_for_task() to make mmap callbacks on initial
attach to a task.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* runtime/task_finder.c (__stp_call_mmap_callbacks_with_addr): Renamed
from __stp_call_mmap_callbacks_with_vma(). Also added some code from
__stp_utrace_task_finder_target_syscall_exit() that locks the 'mmap_sem'
semaphore. This avoids holding the semaphore while the mmap callbacks
are made.
(__stp_utrace_task_finder_target_syscall_exit): Just calls
__stp_call_mmap_callbacks_with_addr() in the mmap case.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* runtime/transport/control.c (_stp_ctl_write_cmd): Calls dbug_trans2
instead of _dbug (so that printk is used instead of the transport
itself).
(_stp_ctl_write_dbug): Ditto.
* runtime/debug.h (dbug_trans2): New macro.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* runtime/transport/control.c (_stp_ctl_write_dbug): Added support for
more messages.
* runtime/transport/relay_v2.c (_stp_transport_data_fs_start): New
function.
(_stp_transport_data_fs_stop): Ditto.
(_stp_transport_data_fs_close): Moved some functionality into
_stp_transport_data_fs_stop() and calls _stp_transport_data_fs_stop()
also.
(_stp_transport_data_fs_init): Moved some functionality into
_stp_transport_data_fs_start() and calls _stp_transport_data_fs_start()
also.
* runtime/transport/relayfs.c (_stp_transport_data_fs_start): New
function.
(_stp_transport_data_fs_stop): Ditto.
(_stp_transport_data_fs_close): Moved some functionality into
_stp_transport_data_fs_stop() and calls _stp_transport_data_fs_stop()
also.
(_stp_transport_data_fs_init): Moved some functionality into
_stp_transport_data_fs_start() and calls _stp_transport_data_fs_start()
also.
* runtime/transport/ring_buffer.c (_stp_transport_data_fs_start): New
empty function.
(_stp_transport_data_fs_stop): Ditto.
* runtime/transport/transport.h: Added _stp_transport_data_fs_start() and
_stp_transport_data_fs_stop() prototypes.
* runtime/transport/transport.c (_stp_cleanup_and_exit): Calls
_stp_transport_data_fs_stop().
(_stp_transport_close): Calls _stp_transport_fs_close() earlier.
(_stp_transport_init): Calls _stp_transport_data_fs_start().
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* runtime/print.h: Moved _stp_reserve_bytes() prototype here.
* runtime/vsprintf.c (_stp_vsnprintf): Includes print.h to get
_stp_reserve_bytes() prototype.
* runtime/transport/transport.c (_stp_remove_root_dir): Better cleanup
for STP_TRANSPORT_VERSION == 1.
(_stp_transport_fs_close): Ditto.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* runtime/vsprintf.c: Added transport.h inclusion for STP_BUFFER_SIZE
definition.
* runtime/transport/debugfs.c (_stp_register_ctl_channel_fs): Added error
checking.
* runtime/transport/transport.c (_stp_get_root_dir): Ditto.
(_stp_transport_fs_init): Added original transport support and error
checking.
* runtime/transport/relay_v2.c (__stp_relay_create_buf_file_callback):
Added error checking.
(_stp_transport_data_fs_init): Ditto.
* runtime/transport/ring_buffer.c (_stp_transport_data_fs_init): Ditto.
* runtime/transport/utt.c: Removed unused file.
* runtime/transport/utt.h: Ditto.
|
| |\ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Conflicts:
runtime/print.c
runtime/transport/transport.c
runtime/transport/transport_msgs.h
|