[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20081106131348.68f8858e@infradead.org>
Date: Thu, 6 Nov 2008 13:13:48 -0800
From: Arjan van de Ven <arjan@...radead.org>
To: fche@...hat.com (Frank Ch. Eigler)
Cc: Steven Rostedt <rostedt@...dmis.org>,
Peter Zijlstra <peterz@...radead.org>,
linux-kernel@...r.kernel.org, mingo@...e.hu, alan@...hat.com,
jbaron@...hat.com
Subject: Re: [PATCH] ftrace: add an fsync tracer
On Thu, 06 Nov 2008 15:19:48 -0500
fche@...hat.com (Frank Ch. Eigler) wrote:
> Arjan van de Ven <arjan@...radead.org> writes:
>
> > [...]
> > what is the real need is
> > 1) Have a trace point in the source
> > 2) Associate a "formatting function" with that point
> > (which basically transforms the trace parameters to, say, a
> > string) 3) A way to turn the trace point on/off.
>
> For 1 and 2, it may be worth considering a plain trace_mark() in
> do_sync(). The complication that makes this uglier than a one-liner
no why is that?
what you really need is to be able to provide a callback function
pointer that will do the formatting,
or as Peter wants it, a format string.
(and we can easily make a format string that knows how to print a
struct file, no big deal, I suspect that is a common thing actually)
Doing this like you propose is just too complex and too specialistic;
the reality is that merely formatting the arguments of a trace point is
the common case, and I suspect for 99.9% of the cases we can get away
with a standard default formatting.
We should make THAT easy. Not complex or ugly. But easy.
And then if I or some tool wants to see a tracepoint, we have some
standard way to enumerate them and turn individual ones on with their
standard formatting ... and that's it.
no iffs or buts
--
Arjan van de Ven Intel Open Source Technology Centre
For development, discussion and tips for power savings,
visit http://www.lesswatts.org
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists