lkml.org 
[lkml]   [2009]   [Feb]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 0/4][RFC] event tracer

On Tue, 24 Feb 2009, Mathieu Desnoyers wrote:

> * Steven Rostedt (rostedt@goodmis.org) wrote:
> >
> > On Tue, 24 Feb 2009, Masami Hiramatsu wrote:
> > > >
> > > > #undef TPFMT
> > > > #define TPFMT(fmt, args...) \
> > > > "(%s)" fmt "\n", #call, ##args
> > > >
> > > > and then I could do
> > > >
> > > > event_printk(fmt);
> > >
> > > Why don't you do as below? :)
> > > event_printk_line("(" #call ")" ##fmtandargs);
> >
> > Still need to sneak that "\n" in ;-)
> >
>
> Why do you need the \n ? Having all event format strings ending with \0
> should be enough to tell event_printk to generate a \n each time it
> encounters a format string \0. Doing so would save 1 byte per format
> string.

Because currently event_printk uses a generic function that acts pretty
much like ftrace_printk.

I like having fmt and args separate. This way, we can add more stuff to
the end if we ever want to. For now it's a '\n'. We can deal with
those extra bytes.

-- Steve



\
 
 \ /
  Last update: 2009-02-25 02:17    [W:1.895 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site