lkml.org 
[lkml]   [2016]   [Feb]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[RFC][PATCH 03/10] tracing: Add an 'accessor' function to ftrace_event_field
Date
For grabbing the contents of an event field from a trace record, it
would be useful to associate a field-specific accessor function with
an event field. This defines an accessor prototype and adds an
accessor field to struct ftrace_event_field for that purpose.

Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com>
---
kernel/trace/trace.h | 5 +++++
1 file changed, 5 insertions(+)

diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h
index fed2ae0..7b48a3c 100644
--- a/kernel/trace/trace.h
+++ b/kernel/trace/trace.h
@@ -1030,11 +1030,16 @@ static inline void trace_branch_disable(void)
/* set ring buffers to default size if not already done so */
int tracing_update_buffers(void);

+struct ftrace_event_field;
+
+typedef u64 (*ftrace_event_field_fn_t) (struct ftrace_event_field *field, void *event);
+
struct ftrace_event_field {
struct list_head link;
const char *name;
const char *type;
int filter_type;
+ ftrace_event_field_fn_t accessor;
int offset;
int size;
int is_signed;
--
1.9.3
\
 
 \ /
  Last update: 2016-02-12 17:21    [W:0.156 / U:0.616 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site