Re: sys_sched_yield keeps locked irq before call of schedule()

From: Steven Rostedt
Date: Thu Nov 06 2008 - 09:47:19 EST



On Thu, 6 Nov 2008, Ingo Molnar wrote:
> >
> > Quick note. Currently ftrace_printk only shows up if it is set in the
> > iter_ctrl.
> >
> > echo trace_printk > /debug/tracing/iter_ctrl
> >
> > I'll send out a patch to have it on by default.
>
> ok, agreed - but in that case please make the NOP tracer
> tracing_enabled=0 by default. (we'll get a lot of ftrace_printk
> tracepoints by default otherwise)

Hmm, I think it may be good to leave it on even for the nop tracer.

ftrace_printk's should not be out in open code unless someone is actually
debugging it. You can use ftrace_printk inside a tracer to write stuff,
but that printk should be protected somehow by the encompassing tracer.

i.e.

some_tracer(void) {
if (!tracer_enabled)
return;
ftrace_printk("my special stuff\n");
}

I would think if someone is debugging their code by using ftrace_printk,
they probably want it to show up right away, without having to remember to
do a...


echo trace_printk > /debug/tracing/iter_ctrl

And still have it show up in the nop tracer.

-- Steve

--
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/