summaryrefslogtreecommitdiffstats
path: root/runtime/procfs.c
Commit message (Collapse)AuthorAgeFilesLines
* Fixed PR 11078. Changed code to avoided procfs race condition.David Smith2010-02-031-4/+11
| | | | | | | | | | | | | | | | | * runtime/procfs.c: Allow STP_MAX_PROCFS_FILES define to be overridden. (_stp_create_procfs): Calls proc_create() instead of create_proc_entry() to avoid a race condition. * runtime/procfs-probes.c: New file containing procfs probe support routines. * tapset-procfs.cxx (procfs_derived_probe::join_group): Update struct _stp_procfs_data definition. (procfs_derived_probe::emit_module_decls): Include procfs-probes.c, which is where the definition of struct stap_procfs_probe exists. Update generated routines to read/write procfs data. (procfs_derived_probe_group::emit_module_init): Pass file_operations argument to _stp_create_procfs(). Initialize mutex. (procfs_var_expanding_visitor::visit_target_symbol): Update generated code.
* BZ 490234 fix.David Smith2009-07-061-8/+7
| | | | | | * 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.
* Removed unused functions and variables.David Smith2009-02-181-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2009-02-18 David Smith <dsmith@redhat.com> * io.c (_stp_log): Removed unused function. * map.c (_stp_cmp): Replace _stp_log() with dbug(). * mempool.c (_stp_mempool_resize): Removed unused function. * print.c (next_fmt): Removed unused function. * procfs.c: Removed unused variable '_stp_num_procfs_files'. * regs.c (_stp_ret_addr): Removed unused function. * string.c (_stp_text_str): Removed unused variable 'len'. * string.h: Removed unused variable '_stdout_' and function declaration for deleted function '_stp_vsprintf'. * sym.c: Removed unused variables. * unwind.c (_stp_create_unwind_hdr): Removed unused function. 2009-02-18 David Smith <dsmith@redhat.com> * control.c: Removed unused variable '_stp_current_buffers'. * procfs.c (_stp_set_buffers): Removed unused function. (_stp_register_ctl_channel_fs): Removed unused variables and label. * symbols.c (u32_swap): Removed unused function. (generic_swap): Ditto. (_stp_sort): Ditto. (_stp_section_is_interesting): Ditto. * transport.c (_stp_transport_init): Removed unused variable 'ret'.
* Fixed transport/procfs.c for systems that use the old transport (RHEL4).David Smith2009-02-131-0/+5
| | | | | | | | | | | 2009-02-13 David Smith <dsmith@redhat.com> * procfs.c: Added macros to guard against multiple inclusion. 2009-02-13 David Smith <dsmith@redhat.com> * procfs.c: Added inclusion of ../procfs.c for _stp_mkdir_proc_module().
* Cleanup. Renamed _stp_{un}lock_debugfs() to _stp_{un}lock_transport_dir().David Smith2009-02-121-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | 2009-02-12 David Smith <dsmith@redhat.com> * transport.c (_stp_lock_transport_dir): Renamed from _stp_lock_debugfs(), since on older kernels this actually uses procfs. (_stp_unlock_transport_dir): Renamed from _stp_unlock_debugfs(), since on older kernels this actually uses procfs. (_stp_lock_transport_dir): Changed _stp_lock_debugfs()/_stp_unlock_debugfs() to _stp_lock_transport_dir()/_stp_unlock_transport_dir(). * transport.h: Ditto. Also added _stp_transport_init() prototype. * utt.c (utt_remove_root): Changed _stp_lock_debugfs()/_stp_unlock_debugfs() to _stp_lock_transport_dir()/_stp_unlock_transport_dir(). * relayfs.c (_stp_remove_relay_root): Ditto. 2009-02-12 David Smith <dsmith@redhat.com> * procfs.c (_stp_rmdir_proc_module): Changed _stp_lock_debugfs()/_stp_unlock_debugfs() to _stp_lock_transport_dir()/_stp_unlock_transport_dir(). (_stp_mkdir_proc_module): Ditto.
* 2.6.29rc build fix: autoconf for proc_dir_entry->owner going awayFrank Ch. Eigler2009-02-061-1/+5
|
* Use 'static' as much as possibleJosh Stone2009-01-281-5/+5
| | | | | | | | | | This change just inserts 'static' on runtime, tapset, and generated C functions and globals, so the compiler can do a better job of optimizing. My tests with small scripts show ~10% reduction in compile time and ~20% reduction in module size. Larger scripts may show less benefit, but I expect purely positive results.
* Remove debug output from warning in procfs.Mark Wielaard2008-10-041-2/+2
|
* procfs dir_entry count warning on removal depends on kernel version.Mark Wielaard2008-10-041-3/+10
|
* From srinivasa@in.ibm.com, To make systemtap to work with register rename ↵srinivasa2008-01-181-0/+6
| | | | patch for x86/x86_64
* 2007-09-19 Martin Hunt <hunt@redhat.com>hunt2007-09-191-3/+19
| | | | | | | | | | PR 5042 * procfs.c (_stp_rmdir_proc_module): Warn if removal of /proc/systemtap/module is deferred. Do not defer removal of /proc/systemtap. (_stp_mkdir_proc_module): Call path_release(). Set ownership of /proc/systemtap/module to force deletion to be deferred. (_stp_create_procfs): Set owner of all path components.
* Remove debug.hunt2007-09-141-1/+0
|
* 2007-09-14 Martin Hunt <hunt@redhat.com>hunt2007-09-141-6/+11
| | | | | * procfs.c (_stp_create_procfs): Be sure that directories in the path are really directories and not files.
* 2007-09-13 David Smith <dsmith@redhat.com>dsmith2007-09-131-10/+7
| | | | | | | | * procfs.c (_stp_procfs_dir_lookup): Added 'const' qualifier to 'dir' parameter. (_stp_create_procfs): Added 'const' qualifier to 'path' parameter. Removed debug prints. (_stp_close_procfs): Removed debug prints.
* 2007-09-10 Martin Hunt <hunt@redhat.com>hunt2007-09-101-0/+177
* procfs.c: New file. Common runtime procfs functions.