diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2023-01-10 07:28:19 +0300 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2023-01-10 07:28:19 +0300 |
commit | 407da561244b9d51e6a794d6305ba38ec2c9d907 (patch) | |
tree | a9b8e399f85eb14f9591fc654ae2372281ffa729 /tools/perf/util/scripting-engines/trace-event-perl.c | |
parent | 144ff5e03d745a299a9aabe2a597da843cf1c430 (diff) | |
parent | b7bfaa761d760e72a969d116517eaa12e404c262 (diff) | |
download | linux-407da561244b9d51e6a794d6305ba38ec2c9d907.tar.xz |
Merge tag 'v6.2-rc3' into next
Merge with mainline to bring in timer_shutdown_sync() API.
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-perl.c')
-rw-r--r-- | tools/perf/util/scripting-engines/trace-event-perl.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/perf/util/scripting-engines/trace-event-perl.c b/tools/perf/util/scripting-engines/trace-event-perl.c index a5d945415bbc..c097b7934fd4 100644 --- a/tools/perf/util/scripting-engines/trace-event-perl.c +++ b/tools/perf/util/scripting-engines/trace-event-perl.c @@ -27,6 +27,7 @@ #include <errno.h> #include <linux/bitmap.h> #include <linux/time64.h> +#include <traceevent/event-parse.h> #include <stdbool.h> /* perl needs the following define, right after including stdbool.h */ @@ -365,7 +366,7 @@ static void perl_process_tracepoint(struct perf_sample *sample, sprintf(handler, "%s::%s", event->system, event->name); - if (!test_and_set_bit(event->id, events_defined)) + if (!__test_and_set_bit(event->id, events_defined)) define_event_symbols(event, handler, event->print_fmt.args); s = nsecs / NSEC_PER_SEC; @@ -392,8 +393,10 @@ static void perl_process_tracepoint(struct perf_sample *sample, if (field->flags & TEP_FIELD_IS_DYNAMIC) { offset = *(int *)(data + field->offset); offset &= 0xffff; +#ifdef HAVE_LIBTRACEEVENT_TEP_FIELD_IS_RELATIVE if (field->flags & TEP_FIELD_IS_RELATIVE) offset += field->offset + field->size; +#endif } else offset = field->offset; XPUSHs(sv_2mortal(newSVpv((char *)data + offset, 0))); |