1. 08 11月, 2008 6 次提交
    • S
      ftrace: enable trace_printk by default · 49833fc2
      Steven Rostedt 提交于
      Impact: have the ftrace_printk enabled on startup
      
      It is confusing to have to "echo trace_printk > /debug/tracing/iter_ctrl"
      after adding ftrace_printk in the kernel.
      
      Currently the trace_printk is set to off by default. ftrace_printk
      should only be in open kernel code when used for debugging, and thus
      it should be enabled by default.
      
      It may also be used to record data within a tracer, but those ftrace_printks
      should be within wrappers that are either enabled by trace_points or
      have a variable protecting the code path from being entered when the
      tracer is disabled.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      49833fc2
    • S
      ftrace: irqsoff tracer incorrect reset · 45193170
      Steven Rostedt 提交于
      Impact: fix to irqsoff tracer output
      
      In converting to the new start / stop ftrace handling, the irqsoff
      tracer start called the irqsoff reset function. irqsoff tracer is
      not the same as the other traces, and it resets the buffers while
      searching for the longest latency.
      
      The reset that the irqsoff stop method calls disables the function
      tracing. That means that, by starting the tracer, the function
      tracer is disabled incorrectly.
      
      This patch simply removes the call to reset which keeps the function
      tracing enabled. Reset is not needed for the irqsoff stop method.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      45193170
    • S
      ftrace: fix sched_switch API · e168e051
      Steven Rostedt 提交于
      Impact: fix for sched_switch that broke dynamic ftrace startup
      
      The commit: tracing/fastboot: use sched switch tracer from boot tracer
      broke the API of the sched_switch trace. The use of the
      tracing_start/stop_cmdline record is for only recording the cmdline,
      NOT recording the schedule switches themselves.
      
      Seeing that the boot tracer broke the API to do something that it
      wanted, this patch adds a new interface for the API while
      puting back the original interface of the old API.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Acked-by: NFrederic Weisbecker <fweisbec@gmail.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      e168e051
    • S
      ftrace: fix boot trace sched startup · 75f5c47d
      Steven Rostedt 提交于
      Impact: boot tracer startup modified
      
      The boot tracer calls into some of the schedule tracing private functions
      that should not be exported. This patch cleans it up, and makes
      way for further changes in the ftrace infrastructure.
      
      This patch adds a api to assign a tracer array to the schedule
      context switch tracer.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Acked-by: NFrederic Weisbecker <fweisbec@gmail.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      75f5c47d
    • S
      ftrace: fix set_ftrace_filter · 0183fb1c
      Steven Rostedt 提交于
      Impact: fix of output of set_ftrace_filter
      
      Commit ftrace: do not show freed records in available_filter_functions
      
      Removed a bit too much from the set_ftrace_filter code, where we now see
      all functions in the set_ftrace_filter file even when we set a filter.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      0183fb1c
    • I
      Merge branches 'tracing/ftrace', 'tracing/fastboot', 'tracing/nmisafe' and... · a6b0786f
      Ingo Molnar 提交于
      Merge branches 'tracing/ftrace', 'tracing/fastboot', 'tracing/nmisafe' and 'tracing/urgent' into tracing/core
      a6b0786f
  2. 07 11月, 2008 1 次提交
  3. 06 11月, 2008 5 次提交
    • S
      ring-buffer: convert to raw spinlocks · 3e03fb7f
      Steven Rostedt 提交于
      Impact: no lockdep debugging of ring buffer
      
      The problem with running lockdep on the ring buffer is that the
      ring buffer is the core infrastructure of ftrace. What happens is
      that the tracer will start tracing the lockdep code while lockdep
      is testing the ring buffers locks.  This can cause lockdep to
      fail due to testing cases that have not fully finished their
      locking transition.
      
      This patch converts the spin locks used by the ring buffer back
      into raw spin locks which lockdep does not check.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      3e03fb7f
    • S
      ftrace: restructure tracing start/stop infrastructure · 9036990d
      Steven Rostedt 提交于
      Impact: change where tracing is started up and stopped
      
      Currently, when a new tracer is selected via echo'ing a tracer name into
      the current_tracer file, the startup is only done if tracing_enabled is
      set to one. If tracing_enabled is changed to zero (by echo'ing 0 into
      the tracing_enabled file) a full shutdown is performed.
      
      The full startup and shutdown of a tracer can be expensive and the
      user can lose out traces when echo'ing in 0 to the tracing_enabled file,
      because the process takes too long. There can also be places that
      the user would like to start and stop the tracer several times and
      doing the full startup and shutdown of a tracer might be too expensive.
      
      This patch performs the full startup and shutdown when a tracer is
      selected. It also adds a way to do a quick start or stop of a tracer.
      The quick version is just a flag that prevents the tracing from
      taking place, but the overhead of the code is still there.
      
      For example, the startup of a tracer may enable tracepoints, or enable
      the function tracer.  The stop and start will just set a flag to
      have the tracer ignore the calls when the tracepoint or function trace
      is called.  The overhead of the tracer may still be present when
      the tracer is stopped, but no tracing will occur. Setting the tracer
      to the 'nop' tracer (or any other tracer) will perform the shutdown
      of the tracer which will disable the tracepoint or disable the
      function tracer.
      
      The tracing_enabled file will simply start or stop tracing.
      
      This change is all internal. The end result for the user should be the same
      as before. If tracing_enabled is not set, no trace will happen.
      If tracing_enabled is set, then the trace will happen. The tracing_enabled
      variable is static between tracers. Enabling  tracing_enabled and
      going to another tracer will keep tracing_enabled enabled. Same
      is true with disabling tracing_enabled.
      
      This patch will now provide a fast start/stop method to the users
      for enabling or disabling tracing.
      
      Note: There were two methods to the struct tracer that were never
       used: The methods start and stop. These were to be used as a hook
       to the reading of the trace output, but ended up not being
       necessary. These two methods are now used to enable the start
       and stop of each tracer, in case the tracer needs to do more than
       just not write into the buffer. For example, the irqsoff tracer
       must stop recording max latencies when tracing is stopped.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      9036990d
    • S
      ftrace: soft tracing stop and start · 0f048701
      Steven Rostedt 提交于
      Impact: add way to quickly start stop tracing from the kernel
      
      This patch adds a soft stop and start to the trace. This simply
      disables function tracing via the ftrace_disabled flag, and
      disables the trace buffers to prevent recording. The tracing
      code may still be executed, but the trace will not be recorded.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      0f048701
    • S
      ftrace: add quick function trace stop · 60a7ecf4
      Steven Rostedt 提交于
      Impact: quick start and stop of function tracer
      
      This patch adds a way to disable the function tracer quickly without
      the need to run kstop_machine. It adds a new variable called
      function_trace_stop which will stop the calls to functions from mcount
      when set.  This is just an on/off switch and does not handle recursion
      like preempt_disable().
      
      It's main purpose is to help other tracers/debuggers start and stop tracing
      fuctions without the need to call kstop_machine.
      
      The config option HAVE_FUNCTION_TRACE_MCOUNT_TEST is added for archs
      that implement the testing of the function_trace_stop in the mcount
      arch dependent code. Otherwise, the test is done in the C code.
      
      x86 is the only arch at the moment that supports this.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      60a7ecf4
    • I
      Merge branch 'tracing/fastboot' into tracing/ftrace · 79c81d22
      Ingo Molnar 提交于
      79c81d22
  4. 05 11月, 2008 7 次提交
  5. 04 11月, 2008 14 次提交
  6. 03 11月, 2008 7 次提交