Sophie

Sophie

distrib > Fedora > 17 > i386 > by-pkgid > e2ec330d3ecf5110b4aa890342e53d96 > files > 774

systemtap-client-2.1-2.fc17.i686.rpm

<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>Chapter&#160;2.&#160;Context Functions</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="SystemTap Tapset Reference Manual"><link rel="up" href="index.html" title="SystemTap Tapset Reference Manual"><link rel="prev" href="introduction.html" title="Chapter&#160;1.&#160;Introduction"><link rel="next" href="API-addr.html" title="function::addr"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter&#160;2.&#160;Context Functions</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="introduction.html">Prev</a>&#160;</td><th width="60%" align="center">&#160;</th><td width="20%" align="right">&#160;<a accesskey="n" href="API-addr.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter&#160;2.&#160;Context Functions"><div class="titlepage"><div><div><h2 class="title"><a name="context_stp"></a>Chapter&#160;2.&#160;Context Functions</h2></div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="refentrytitle"><a href="API-addr.html"><span>function::addr</span></a></span><span class="refpurpose"> &#8212; 
     Address of the current probe point.
 </span></dt><dt><span class="refentrytitle"><a href="API-asmlinkage.html"><span>function::asmlinkage</span></a></span><span class="refpurpose"> &#8212; 
     Mark function as declared asmlinkage
 </span></dt><dt><span class="refentrytitle"><a href="API-backtrace.html"><span>function::backtrace</span></a></span><span class="refpurpose"> &#8212; 
     Hex backtrace of current kernel stack
 </span></dt><dt><span class="refentrytitle"><a href="API-caller.html"><span>function::caller</span></a></span><span class="refpurpose"> &#8212; 
     Return name and address of calling function
 </span></dt><dt><span class="refentrytitle"><a href="API-caller-addr.html"><span>function::caller_addr</span></a></span><span class="refpurpose"> &#8212; 
     Return caller address
 </span></dt><dt><span class="refentrytitle"><a href="API-callers.html"><span>function::callers</span></a></span><span class="refpurpose"> &#8212; 
  Return first n elements of kernel stack backtrace
 </span></dt><dt><span class="refentrytitle"><a href="API-cmdline-arg.html"><span>function::cmdline_arg</span></a></span><span class="refpurpose"> &#8212; 
     Fetch a command line argument
 </span></dt><dt><span class="refentrytitle"><a href="API-cmdline-args.html"><span>function::cmdline_args</span></a></span><span class="refpurpose"> &#8212; 
     Fetch command line arguments from current process
 </span></dt><dt><span class="refentrytitle"><a href="API-cmdline-str.html"><span>function::cmdline_str</span></a></span><span class="refpurpose"> &#8212; 
     Fetch all command line arguments from current process
 </span></dt><dt><span class="refentrytitle"><a href="API-cpu.html"><span>function::cpu</span></a></span><span class="refpurpose"> &#8212; 
     Returns the current cpu number
 </span></dt><dt><span class="refentrytitle"><a href="API-cpuid.html"><span>function::cpuid</span></a></span><span class="refpurpose"> &#8212; 
     Returns the current cpu number
 </span></dt><dt><span class="refentrytitle"><a href="API-egid.html"><span>function::egid</span></a></span><span class="refpurpose"> &#8212; 
     Returns the effective gid of a target process
 </span></dt><dt><span class="refentrytitle"><a href="API-env-var.html"><span>function::env_var</span></a></span><span class="refpurpose"> &#8212; 
  Fetch environment variable from current process
 </span></dt><dt><span class="refentrytitle"><a href="API-euid.html"><span>function::euid</span></a></span><span class="refpurpose"> &#8212; 
     Return the effective uid of a target process
 </span></dt><dt><span class="refentrytitle"><a href="API-execname.html"><span>function::execname</span></a></span><span class="refpurpose"> &#8212; 
  Returns the execname of a target process (or group of processes)
 </span></dt><dt><span class="refentrytitle"><a href="API-fastcall.html"><span>function::fastcall</span></a></span><span class="refpurpose"> &#8212; 
     Mark function as declared fastcall
 </span></dt><dt><span class="refentrytitle"><a href="API-gid.html"><span>function::gid</span></a></span><span class="refpurpose"> &#8212; 
     Returns the group ID of a target process
 </span></dt><dt><span class="refentrytitle"><a href="API-int-arg.html"><span>function::int_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as signed int
 </span></dt><dt><span class="refentrytitle"><a href="API-is-myproc.html"><span>function::is_myproc</span></a></span><span class="refpurpose"> &#8212; 
     Determines if the current probe point has occurred in the user's own process
 </span></dt><dt><span class="refentrytitle"><a href="API-is-return.html"><span>function::is_return</span></a></span><span class="refpurpose"> &#8212; 
     Whether the current probe context is a return probe
 </span></dt><dt><span class="refentrytitle"><a href="API-long-arg.html"><span>function::long_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as signed long
 </span></dt><dt><span class="refentrytitle"><a href="API-longlong-arg.html"><span>function::longlong_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as 64-bit value
 </span></dt><dt><span class="refentrytitle"><a href="API-modname.html"><span>function::modname</span></a></span><span class="refpurpose"> &#8212; 
     Return the kernel module name loaded at the address
 </span></dt><dt><span class="refentrytitle"><a href="API-module-name.html"><span>function::module_name</span></a></span><span class="refpurpose"> &#8212; 
     The module name of the current script
 </span></dt><dt><span class="refentrytitle"><a href="API-pexecname.html"><span>function::pexecname</span></a></span><span class="refpurpose"> &#8212; 
     Returns the execname of a target process's parent process
 </span></dt><dt><span class="refentrytitle"><a href="API-pgrp.html"><span>function::pgrp</span></a></span><span class="refpurpose"> &#8212; 
     Returns the process group ID of the current process
 </span></dt><dt><span class="refentrytitle"><a href="API-pid.html"><span>function::pid</span></a></span><span class="refpurpose"> &#8212; 
     Returns the ID of a target process
 </span></dt><dt><span class="refentrytitle"><a href="API-pid2execname.html"><span>function::pid2execname</span></a></span><span class="refpurpose"> &#8212; 
     The name of the given process identifier
 </span></dt><dt><span class="refentrytitle"><a href="API-pid2task.html"><span>function::pid2task</span></a></span><span class="refpurpose"> &#8212; 
     The task_struct of the given process identifier
 </span></dt><dt><span class="refentrytitle"><a href="API-pn.html"><span>function::pn</span></a></span><span class="refpurpose"> &#8212; 
  Returns the active probe name
 </span></dt><dt><span class="refentrytitle"><a href="API-pointer-arg.html"><span>function::pointer_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as pointer value
 </span></dt><dt><span class="refentrytitle"><a href="API-pp.html"><span>function::pp</span></a></span><span class="refpurpose"> &#8212; 
     Returns the active probe point
 </span></dt><dt><span class="refentrytitle"><a href="API-ppfunc.html"><span>function::ppfunc</span></a></span><span class="refpurpose"> &#8212; 
     Returns the function name parsed from <code class="function">pp</code>
 </span></dt><dt><span class="refentrytitle"><a href="API-ppid.html"><span>function::ppid</span></a></span><span class="refpurpose"> &#8212; 
     Returns the process ID of a target process's parent process
 </span></dt><dt><span class="refentrytitle"><a href="API-print-backtrace.html"><span>function::print_backtrace</span></a></span><span class="refpurpose"> &#8212; 
  Print kernel stack back trace
 </span></dt><dt><span class="refentrytitle"><a href="API-print-regs.html"><span>function::print_regs</span></a></span><span class="refpurpose"> &#8212; 
  Print a register dump
 </span></dt><dt><span class="refentrytitle"><a href="API-print-stack.html"><span>function::print_stack</span></a></span><span class="refpurpose"> &#8212; 
     Print out kernel stack from string
 </span></dt><dt><span class="refentrytitle"><a href="API-print-syms.html"><span>function::print_syms</span></a></span><span class="refpurpose"> &#8212; 
     Print out kernel stack from string
 </span></dt><dt><span class="refentrytitle"><a href="API-print-ubacktrace.html"><span>function::print_ubacktrace</span></a></span><span class="refpurpose"> &#8212; 
  Print stack back trace for current user-space task.
 </span></dt><dt><span class="refentrytitle"><a href="API-print-ubacktrace-brief.html"><span>function::print_ubacktrace_brief</span></a></span><span class="refpurpose"> &#8212; 
     Print stack back trace for current user-space task.
 </span></dt><dt><span class="refentrytitle"><a href="API-print-ustack.html"><span>function::print_ustack</span></a></span><span class="refpurpose"> &#8212; 
     Print out stack for the current task from string.
 </span></dt><dt><span class="refentrytitle"><a href="API-print-usyms.html"><span>function::print_usyms</span></a></span><span class="refpurpose"> &#8212; 
     Print out user stack from string
 </span></dt><dt><span class="refentrytitle"><a href="API-probe-type.html"><span>function::probe_type</span></a></span><span class="refpurpose"> &#8212; 
     The low level probe handler type of the current probe.
 </span></dt><dt><span class="refentrytitle"><a href="API-probefunc.html"><span>function::probefunc</span></a></span><span class="refpurpose"> &#8212; 
     Return the probe point's function name, if known
 </span></dt><dt><span class="refentrytitle"><a href="API-probemod.html"><span>function::probemod</span></a></span><span class="refpurpose"> &#8212; 
     Return the probe point's kernel module name
 </span></dt><dt><span class="refentrytitle"><a href="API-pstrace.html"><span>function::pstrace</span></a></span><span class="refpurpose"> &#8212; 
  Chain of processes and pids back to init(1)
 </span></dt><dt><span class="refentrytitle"><a href="API-register.html"><span>function::register</span></a></span><span class="refpurpose"> &#8212; 
  Return the signed value of the named CPU register
 </span></dt><dt><span class="refentrytitle"><a href="API-registers-valid.html"><span>function::registers_valid</span></a></span><span class="refpurpose"> &#8212; 
     Determines validity of <code class="function">register</code> and <code class="function">u_register</code> in current context
 </span></dt><dt><span class="refentrytitle"><a href="API-regparm.html"><span>function::regparm</span></a></span><span class="refpurpose"> &#8212; 
     Specify regparm value used to compile function
 </span></dt><dt><span class="refentrytitle"><a href="API-remote-id.html"><span>function::remote_id</span></a></span><span class="refpurpose"> &#8212; 
     The index of this instance in a remote execution.
 </span></dt><dt><span class="refentrytitle"><a href="API-remote-uri.html"><span>function::remote_uri</span></a></span><span class="refpurpose"> &#8212; 
     The name of this instance in a remote execution.
 </span></dt><dt><span class="refentrytitle"><a href="API-s32-arg.html"><span>function::s32_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as signed 32-bit value
 </span></dt><dt><span class="refentrytitle"><a href="API-s64-arg.html"><span>function::s64_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as signed 64-bit value
 </span></dt><dt><span class="refentrytitle"><a href="API-sid.html"><span>function::sid</span></a></span><span class="refpurpose"> &#8212; 
     Returns the session ID of the current process
 </span></dt><dt><span class="refentrytitle"><a href="API-sprint-backtrace.html"><span>function::sprint_backtrace</span></a></span><span class="refpurpose"> &#8212; 
     Return stack back trace as string
 </span></dt><dt><span class="refentrytitle"><a href="API-sprint-stack.html"><span>function::sprint_stack</span></a></span><span class="refpurpose"> &#8212; 
     Return stack for kernel addresses from string
 </span></dt><dt><span class="refentrytitle"><a href="API-sprint-syms.html"><span>function::sprint_syms</span></a></span><span class="refpurpose"> &#8212; 
     Return stack for kernel addresses from string
 </span></dt><dt><span class="refentrytitle"><a href="API-sprint-ubacktrace.html"><span>function::sprint_ubacktrace</span></a></span><span class="refpurpose"> &#8212; 
     Return stack back trace for current user-space task as string.
 </span></dt><dt><span class="refentrytitle"><a href="API-sprint-ustack.html"><span>function::sprint_ustack</span></a></span><span class="refpurpose"> &#8212; 
     Return stack for the current task from string.
 </span></dt><dt><span class="refentrytitle"><a href="API-sprint-usyms.html"><span>function::sprint_usyms</span></a></span><span class="refpurpose"> &#8212; 
     Return stack for user addresses from string
 </span></dt><dt><span class="refentrytitle"><a href="API-stack.html"><span>function::stack</span></a></span><span class="refpurpose"> &#8212; 
  Return address at given depth of kernel stack backtrace
 </span></dt><dt><span class="refentrytitle"><a href="API-stack-size.html"><span>function::stack_size</span></a></span><span class="refpurpose"> &#8212; 
     Return the size of the kernel stack
 </span></dt><dt><span class="refentrytitle"><a href="API-stack-unused.html"><span>function::stack_unused</span></a></span><span class="refpurpose"> &#8212; 
     Returns the amount of kernel stack currently available
 </span></dt><dt><span class="refentrytitle"><a href="API-stack-used.html"><span>function::stack_used</span></a></span><span class="refpurpose"> &#8212; 
     Returns the amount of kernel stack used
 </span></dt><dt><span class="refentrytitle"><a href="API-stp-pid.html"><span>function::stp_pid</span></a></span><span class="refpurpose"> &#8212; 
     The process id of the stapio process
 </span></dt><dt><span class="refentrytitle"><a href="API-symdata.html"><span>function::symdata</span></a></span><span class="refpurpose"> &#8212; 
     Return the kernel symbol and module offset for the address
 </span></dt><dt><span class="refentrytitle"><a href="API-symname.html"><span>function::symname</span></a></span><span class="refpurpose"> &#8212; 
     Return the kernel symbol associated with the given address
 </span></dt><dt><span class="refentrytitle"><a href="API-target.html"><span>function::target</span></a></span><span class="refpurpose"> &#8212; 
     Return the process ID of the target process
 </span></dt><dt><span class="refentrytitle"><a href="API-task-backtrace.html"><span>function::task_backtrace</span></a></span><span class="refpurpose"> &#8212; 
     Hex backtrace of an arbitrary task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-cpu.html"><span>function::task_cpu</span></a></span><span class="refpurpose"> &#8212; 
     The scheduled cpu of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-current.html"><span>function::task_current</span></a></span><span class="refpurpose"> &#8212; 
  The current task_struct of the current task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-egid.html"><span>function::task_egid</span></a></span><span class="refpurpose"> &#8212; 
     The effective group identifier of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-euid.html"><span>function::task_euid</span></a></span><span class="refpurpose"> &#8212; 
     The effective user identifier of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-execname.html"><span>function::task_execname</span></a></span><span class="refpurpose"> &#8212; 
     The name of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-gid.html"><span>function::task_gid</span></a></span><span class="refpurpose"> &#8212; 
     The group identifier of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-max-file-handles.html"><span>function::task_max_file_handles</span></a></span><span class="refpurpose"> &#8212; 
     The max number of open files for the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-nice.html"><span>function::task_nice</span></a></span><span class="refpurpose"> &#8212; 
     The nice value of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-open-file-handles.html"><span>function::task_open_file_handles</span></a></span><span class="refpurpose"> &#8212; 
     The number of open files of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-parent.html"><span>function::task_parent</span></a></span><span class="refpurpose"> &#8212; 
     The task_struct of the parent task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-pid.html"><span>function::task_pid</span></a></span><span class="refpurpose"> &#8212; 
     The process identifier of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-prio.html"><span>function::task_prio</span></a></span><span class="refpurpose"> &#8212; 
     The priority value of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-state.html"><span>function::task_state</span></a></span><span class="refpurpose"> &#8212; 
     The state of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-tid.html"><span>function::task_tid</span></a></span><span class="refpurpose"> &#8212; 
     The thread identifier of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-task-uid.html"><span>function::task_uid</span></a></span><span class="refpurpose"> &#8212; 
     The user identifier of the task
 </span></dt><dt><span class="refentrytitle"><a href="API-tid.html"><span>function::tid</span></a></span><span class="refpurpose"> &#8212; 
     Returns the thread ID of a target process
 </span></dt><dt><span class="refentrytitle"><a href="API-u32-arg.html"><span>function::u32_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as unsigned 32-bit value
 </span></dt><dt><span class="refentrytitle"><a href="API-u64-arg.html"><span>function::u64_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as unsigned 64-bit value
 </span></dt><dt><span class="refentrytitle"><a href="API-u-register.html"><span>function::u_register</span></a></span><span class="refpurpose"> &#8212; 
     Return the unsigned value of the named CPU register
 </span></dt><dt><span class="refentrytitle"><a href="API-uaddr.html"><span>function::uaddr</span></a></span><span class="refpurpose"> &#8212; 
     User space address of current running task
 </span></dt><dt><span class="refentrytitle"><a href="API-ubacktrace.html"><span>function::ubacktrace</span></a></span><span class="refpurpose"> &#8212; 
     Hex backtrace of current user-space task stack.
 </span></dt><dt><span class="refentrytitle"><a href="API-ucallers.html"><span>function::ucallers</span></a></span><span class="refpurpose"> &#8212; 
     Return first n elements of user stack backtrace
 </span></dt><dt><span class="refentrytitle"><a href="API-uid.html"><span>function::uid</span></a></span><span class="refpurpose"> &#8212; 
     Returns the user ID of a target process
 </span></dt><dt><span class="refentrytitle"><a href="API-uint-arg.html"><span>function::uint_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as unsigned int
 </span></dt><dt><span class="refentrytitle"><a href="API-ulong-arg.html"><span>function::ulong_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as unsigned long
 </span></dt><dt><span class="refentrytitle"><a href="API-ulonglong-arg.html"><span>function::ulonglong_arg</span></a></span><span class="refpurpose"> &#8212; 
     Return function argument as 64-bit value
 </span></dt><dt><span class="refentrytitle"><a href="API-umodname.html"><span>function::umodname</span></a></span><span class="refpurpose"> &#8212; 
  Returns the (short) name of the user module.
 </span></dt><dt><span class="refentrytitle"><a href="API-user-mode.html"><span>function::user_mode</span></a></span><span class="refpurpose"> &#8212; 
     Determines if probe point occurs in user-mode
 </span></dt><dt><span class="refentrytitle"><a href="API-ustack.html"><span>function::ustack</span></a></span><span class="refpurpose"> &#8212; 
  Return address at given depth of user stack backtrace
 </span></dt><dt><span class="refentrytitle"><a href="API-usymdata.html"><span>function::usymdata</span></a></span><span class="refpurpose"> &#8212; 
     Return the symbol and module offset of an address.
 </span></dt><dt><span class="refentrytitle"><a href="API-usymname.html"><span>function::usymname</span></a></span><span class="refpurpose"> &#8212; 
     Return the symbol of an address in the current task.
 </span></dt></dl></div><p>
      The context functions provide additional information about where
      an event occurred.
      These functions can provide information such as a backtrace to 
      where the event occurred
      and the current register values for the processor.
    </p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="introduction.html">Prev</a>&#160;</td><td width="20%" align="center">&#160;</td><td width="40%" align="right">&#160;<a accesskey="n" href="API-addr.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter&#160;1.&#160;Introduction&#160;</td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top">&#160;<span>function::addr</span></td></tr></table></div></body></html>