lkml.org 
[lkml]   [2008]   [Dec]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [ltt-dev] [PATCH] Simple LTTng userspace events through debugfs
* Ingo Molnar (mingo@elte.hu) wrote:
>
> * Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca> wrote:
>
> > Hi,
> >
> > I looked at kmemtrace and noticed that the presence of a debugfs
> > "marker" file, which lets userspace write events into the trace buffers.
> >
> > So I just did the same with a
> >
> > /debugfs/ltt/write_event
>
> you mean similar to ftrace's /debug/tracing/trace_marker ? ;-)
>

Quite similar, yes :)

Looking at tracing_mark_write(), I am wondering if the fact that it
returns a count including the added \n is an expected side effect ? A
write() returning a count larger than the number of bytes written seems
to be a bit unexpected... But if we remove the \n from the count, then
the case where one write \0 into the event content would end up doing an
endless loop.

Mathieu

> Ingo
>
> _______________________________________________
> ltt-dev mailing list
> ltt-dev@lists.casi.polymtl.ca
> http://lists.casi.polymtl.ca/cgi-bin/mailman/listinfo/ltt-dev
>

--
Mathieu Desnoyers
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68


\
 
 \ /
  Last update: 2008-12-17 05:19    [W:0.065 / U:1.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site