lkml.org 
[lkml]   [2011]   [Dec]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: trace_printk is doing weird things with my arguments
From
Date
On Mon, 2011-12-12 at 15:32 -0500, Josef Bacik wrote:
>
> That worked perfectly. So will I have this problem when I got to turn these
> things into tracepoints or will those work out right? Thanks,

The TP_fast_assign() is exactly how things are copied into the ring
buffer. If you have all the necessary data copied then, and don't
dereference it in TP_printk(), then you are fine.

IOW,

TP_fast_assign( entry->id = ptr->id),
TP_printk ("id: %lx", entry->id)

will work, but

TP_fast_assign(entry->ptr = ptr),
TP_printk("id: %lx", entry->ptr->id)

will not.


-- Steve




\
 
 \ /
  Last update: 2011-12-12 21:47    [W:0.055 / U:0.152 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site