Re: [PATCH] Update old Mini-HOWTO for ftrace

From: GeunSik Lim
Date: Tue Apr 07 2009 - 00:37:31 EST


> What's the chrt for?
We often need simple test to get latency result of realtime using
"current_tracers" file.
In this case, We can run easy testcase as realtime task with the chrt command.

Although we usually use function tracer for tracing internal kernel
functions by ftraced.
I think that we need simple example like the chrt for monitoring
latencies and the kernel
functoins using sleep command as realtime task.


2009/4/7 Steven Rostedt <srostedt@xxxxxxxxxx>:
>
> On Mon, 2009-04-06 at 23:17 +0900, GeunSik Lim wrote:
>> I attached patch file again because no-operation is changed
>> from "none"word to "nop" word.
>>
>> for example,
>> - Â Â Â "wakeup preemptirqsoff preemptoff irqsoff ftrace sched_switch none\n\n"
>> + Â Â Â "wakeup preemptirqsoff preemptoff irqsoff function sched_switch nop\n\n"
>>
>> ./trace_nop.c:struct tracer nop_trace __read_mostly =
>>    .name  = "nop",
>>    .init      = nop_trace_init,
>> Â Â Â .reset Â= nop_trace_reset,
>>    .selftest    = trace_selftest_startup_nop,
>> Â Â Â .flags Â= &nop_flags,
>>    .set_flag    = nop_set_flag
>>
>>
>>
>> 2009/4/6 GeunSik Lim <leemgs1@xxxxxxxxx>:
>> > Â Dear Steven,
>> >
>> > Â The author of ftrace(Internal kernel Function Tracer) feature
>> > renamed the ftrace tracer
>> > Â Âto function to avoid further confusion between the ftrace
>> > infrastructure and the
>> > Â Âfunction tracer on Oct-20, 2008.
>> >
>> > Â ÂBut, Update of Mini-HOWTO document are still not working
>> > Â Â.
>> > Â ÂMost of the developers often utilize "/debug/tracing/README" file
>> > as Mini-HOWTO.
>> > Â ÂThey will confuse definition and usage about ftrace Âbetween
>> > README(ftrace) file
>> > Â Âand available_tracers(function) file after linux-2.6.27 like me.
>> > Â ÂAnd, I want you to append "chrt -f 5 sleep 1" command as simple
>> > example for latency.
>> >
>> > Â ÂSigned-off-by: GeunSik Lim <leemgs1@xxxxxxxxx>
>> > Â ÂSigned-off-by: Steven Rostedt <srostedt@xxxxxxxxxx>
>> > Â ÂSigned-off-by: Ingo Molnar <mingo@xxxxxxx>
>> > ---
>> > Âkernel/trace/trace.c | Â Â3 ++-
>> > Â1 files changed, 2 insertions(+), 1 deletions(-)
>> >
>> > diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
>> > index a0174a4..15f0eec 100644
>> > --- a/kernel/trace/trace.c
>> > +++ b/kernel/trace/trace.c
>> > @@ -2358,7 +2358,7 @@ static const char readme_msg[] =
>> > Â Â Â Â"# mkdir /debug\n"
>> > Â Â Â Â"# mount -t debugfs nodev /debug\n\n"
>> > Â Â Â Â"# cat /debug/tracing/available_tracers\n"
>> > - Â Â Â "wakeup preemptirqsoff preemptoff irqsoff ftrace sched_switch none\n\n"
>> > + Â Â Â "wakeup preemptirqsoff preemptoff irqsoff function
>> > sched_switch none\n\n"
>> > Â Â Â Â"# cat /debug/tracing/current_tracer\n"
>> > Â Â Â Â"none\n"
>> > Â Â Â Â"# echo sched_switch > /debug/tracing/current_tracer\n"
>> > @@ -2368,6 +2368,7 @@ static const char readme_msg[] =
>> > Â Â Â Â"noprint-parent nosym-offset nosym-addr noverbose\n"
>> > Â Â Â Â"# echo print-parent > /debug/tracing/trace_options\n"
>> > Â Â Â Â"# echo 1 > /debug/tracing/tracing_enabled\n"
>> > + Â Â Â "# chrt -f 5 sleep 1\n"
>
>
> What's the chrt for?
>
> -- Steve
>
>
>



--
Regards,
GeunSik Lim
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/