aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrederic Weisbecker <fweisbec@gmail.com>2012-05-22 10:30:49 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2012-05-22 11:32:29 -0400
commit8784eb7497b928de33a715e26da2bd51d424bec1 (patch)
tree8d3a57c649bbbf8d963b332ba5164240ee5699f3
parente326e7524531c5c6de4a8cf8eeed60b4a9f47637 (diff)
perf script: Rename struct event to struct event_format in perl engine
While migrating to the libtraceevent, the perl scripting engine missed this structure rename. This fixes: util/scripting-engines/trace-event-perl.c: In function "find_cache_event": util/scripting-engines/trace-event-perl.c:244: error: assignment from incompatible pointer type util/scripting-engines/trace-event-perl.c:248: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:248: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:250: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c: In function "perl_process_tracepoint": util/scripting-engines/trace-event-perl.c:286: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:286: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:307: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c: In function "perl_generate_script": util/scripting-engines/trace-event-perl.c:498: error: passing argument 1 of "trace_find_next_event" from incompatible pointer type util/scripting-engines/../trace-event.h:56: note: expected "struct event_format *" but argument is of type "struct event *" util/scripting-engines/trace-event-perl.c:498: error: assignment from incompatible pointer type util/scripting-engines/trace-event-perl.c:499: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:499: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:513: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:532: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:556: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:569: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:570: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:579: error: dereferencing pointer to incomplete type util/scripting-engines/trace-event-perl.c:580: error: dereferencing pointer to incomplete type Reported-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Frederic Weisbecker <fweisbec@redhat.com> Cc: Frederic Weisbecker <fweisbec@redhat.com> Cc: Ingo Molnar <mingo@kernel.org> Cc: Namhyung Kim <namhyung.kim@lge.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Tom Zanussi <tzanussi@gmail.com> Link: http://lkml.kernel.org/r/1337697049-30251-2-git-send-email-fweisbec@gmail.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
-rw-r--r--tools/perf/util/scripting-engines/trace-event-perl.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/perf/util/scripting-engines/trace-event-perl.c b/tools/perf/util/scripting-engines/trace-event-perl.c
index d50658b7d9e0..4c1b3d72a1d2 100644
--- a/tools/perf/util/scripting-engines/trace-event-perl.c
+++ b/tools/perf/util/scripting-engines/trace-event-perl.c
@@ -56,7 +56,7 @@ INTERP my_perl;
56#define FTRACE_MAX_EVENT \ 56#define FTRACE_MAX_EVENT \
57 ((1 << (sizeof(unsigned short) * 8)) - 1) 57 ((1 << (sizeof(unsigned short) * 8)) - 1)
58 58
59struct event *events[FTRACE_MAX_EVENT]; 59struct event_format *events[FTRACE_MAX_EVENT];
60 60
61extern struct scripting_context *scripting_context; 61extern struct scripting_context *scripting_context;
62 62
@@ -181,7 +181,7 @@ static void define_flag_field(const char *ev_name,
181 LEAVE; 181 LEAVE;
182} 182}
183 183
184static void define_event_symbols(struct event *event, 184static void define_event_symbols(struct event_format *event,
185 const char *ev_name, 185 const char *ev_name,
186 struct print_arg *args) 186 struct print_arg *args)
187{ 187{
@@ -233,10 +233,10 @@ static void define_event_symbols(struct event *event,
233 define_event_symbols(event, ev_name, args->next); 233 define_event_symbols(event, ev_name, args->next);
234} 234}
235 235
236static inline struct event *find_cache_event(int type) 236static inline struct event_format *find_cache_event(int type)
237{ 237{
238 static char ev_name[256]; 238 static char ev_name[256];
239 struct event *event; 239 struct event_format *event;
240 240
241 if (events[type]) 241 if (events[type])
242 return events[type]; 242 return events[type];
@@ -262,7 +262,7 @@ static void perl_process_tracepoint(union perf_event *pevent __unused,
262 static char handler[256]; 262 static char handler[256];
263 unsigned long long val; 263 unsigned long long val;
264 unsigned long s, ns; 264 unsigned long s, ns;
265 struct event *event; 265 struct event_format *event;
266 int type; 266 int type;
267 int pid; 267 int pid;
268 int cpu = sample->cpu; 268 int cpu = sample->cpu;
@@ -450,7 +450,7 @@ static int perl_stop_script(void)
450 450
451static int perl_generate_script(const char *outfile) 451static int perl_generate_script(const char *outfile)
452{ 452{
453 struct event *event = NULL; 453 struct event_format *event = NULL;
454 struct format_field *f; 454 struct format_field *f;
455 char fname[PATH_MAX]; 455 char fname[PATH_MAX];
456 int not_first, count; 456 int not_first, count;