lkml.org 
[lkml]   [2011]   [Mar]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH] ftrace: add 'version' special file for ring buffer format
On Mon, Mar 14, 2011 at 7:31 PM, Steven Rostedt <rostedt@goodmis.org> wrote:
> On Mon, 2011-03-14 at 15:42 -0700, Slava Pestov wrote:
>> The intention here is that if the ftrace ring buffer format changes
>> in the future like it did in the past with ktrace, we can increment
>> the version number and update clients appropriately.
>
> I purposely avoided "versions", and instead use the
> tracing/events/header_page and .../header_event to describe how the ring
> buffer format is laid out. If the format changes, then so should those
> files.
>
> -- Steve

Those are useful files, but do not encompass the entirety of the API.
Specifically, they do not encode the semantics of those values, nor
the control interface.

For example, when the ring buffer header changed from type:2;len:3 to
type_len:5, while this would have been reflected in header_event, how
to interpret the different versions is not something that could be
automatically understood by a parser.

These files also do not cover the semantics of the control files. For
example, it is imaginable that buffer_size_kb could be changed from
per-core size to a total size, or that it would reflect the actual
total amount of memory used, instead of the "non-header" space. The
grammar of filter expressions is another example of something that
could change without notice.

d#

>
>>
>> Tested: Verified that special file contains correct content
>>
>> This patch is against 2.6.38-rc8 but should apply to any version
>> from at least 2.6.34 onwards.
>>
>> Signed-Off-By: Slava Pestov <slavapestov@google.com>
>
>
>


\
 
 \ /
  Last update: 2011-03-16 01:37    [W:0.037 / U:0.728 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site