lkml.org 
[lkml]   [2008]   [Nov]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH] ftrace: add an fsync tracer
    On Thu, 06 Nov 2008 15:19:48 -0500
    fche@redhat.com (Frank Ch. Eigler) wrote:

    > Arjan van de Ven <arjan@infradead.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


    \
     
     \ /
      Last update: 2008-11-06 22:15    [W:4.064 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site