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
Steven Rostedt wrote:
> On Tue, 24 Feb 2009, Peter Zijlstra wrote:
>
>> On Tue, 2009-02-24 at 14:33 -0500, Steven Rostedt wrote:
>>
>>> DECLARE_TRACE_FMT(sched_kthread_stop,
>>> TPPROTO(struct task_struct *t),
>>> TPARGS(t),
>>> "task %s:%d", TPARGS(t->comm, t->pid));
>> Consistency would require something like:
>>
>> DECLARE_TRACE_FMT(sched_kthread_stop,
>> TPPROTO(struct task_struct *t),
>> TPARGS(t),
>> TPFMT("task %s:%d", t->comm, t->pid));
>>
>> I seem to remember Jason proposing something like this in the past.
>
> Hmm, I'll have to look at that. (althought I was going to use a different
> TPARGS for the format args.)
>
> I have, for now:
>
> event_printk("(%s)" fmt "\n", #call, fmtargs);
>
> I guess I can redefine the TPFMT too.
>
> #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);

Anyway, your proposal is good for me, because it will recover
an information which tracepoint has lost.

Thank you!

--
Masami Hiramatsu

Software Engineer
Hitachi Computer Products (America) Inc.
Software Solutions Division

e-mail: mhiramat@redhat.com



\
 
 \ /
  Last update: 2009-02-24 23:29    [W:1.859 / U:0.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site