diff options
author | Petr Mladek <pmladek@suse.com> | 2021-08-30 14:56:06 +0200 |
---|---|---|
committer | Petr Mladek <pmladek@suse.com> | 2021-08-30 14:56:06 +0200 |
commit | 71af75b6929458d85f63c0649dc26d6f4c19729e (patch) | |
tree | c05c57903424d8270f6b6f3ec3493791fdba4e5c /tools/perf/util/scripting-engines/trace-event-perl.c | |
parent | fe8e3ee0d588566c1f44f28a555042ef50eba491 (diff) | |
parent | bc17bed5fd73ef1a9aed39f3b0ea26936dad60b8 (diff) | |
download | linux-71af75b6929458d85f63c0649dc26d6f4c19729e.tar.gz linux-71af75b6929458d85f63c0649dc26d6f4c19729e.tar.bz2 linux-71af75b6929458d85f63c0649dc26d6f4c19729e.zip |
Merge branch 'for-5.15-printk-index' into for-linus
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-perl.c')
-rw-r--r-- | tools/perf/util/scripting-engines/trace-event-perl.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/tools/perf/util/scripting-engines/trace-event-perl.c b/tools/perf/util/scripting-engines/trace-event-perl.c index 0e608a5ef599..32a721b3e9a5 100644 --- a/tools/perf/util/scripting-engines/trace-event-perl.c +++ b/tools/perf/util/scripting-engines/trace-event-perl.c @@ -371,9 +371,6 @@ static void perl_process_tracepoint(struct perf_sample *sample, s = nsecs / NSEC_PER_SEC; ns = nsecs - s * NSEC_PER_SEC; - scripting_context->event_data = data; - scripting_context->pevent = evsel->tp_format->tep; - ENTER; SAVETMPS; PUSHMARK(SP); @@ -456,8 +453,10 @@ static void perl_process_event_generic(union perf_event *event, static void perl_process_event(union perf_event *event, struct perf_sample *sample, struct evsel *evsel, - struct addr_location *al) + struct addr_location *al, + struct addr_location *addr_al) { + scripting_context__update(scripting_context, event, sample, evsel, al, addr_al); perl_process_tracepoint(sample, evsel, al); perl_process_event_generic(event, sample, evsel); } @@ -474,11 +473,14 @@ static void run_start_sub(void) /* * Start trace script */ -static int perl_start_script(const char *script, int argc, const char **argv) +static int perl_start_script(const char *script, int argc, const char **argv, + struct perf_session *session) { const char **command_line; int i, err = 0; + scripting_context->session = session; + command_line = malloc((argc + 2) * sizeof(const char *)); command_line[0] = ""; command_line[1] = script; @@ -750,6 +752,7 @@ sub print_backtrace\n\ struct scripting_ops perl_scripting_ops = { .name = "Perl", + .dirname = "perl", .start_script = perl_start_script, .flush_script = perl_flush_script, .stop_script = perl_stop_script, |