diff options
Diffstat (limited to 'tools/perf/util/event.c')
-rw-r--r-- | tools/perf/util/event.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/perf/util/event.c b/tools/perf/util/event.c index c3831f633dec..9eb7005bc6d6 100644 --- a/tools/perf/util/event.c +++ b/tools/perf/util/event.c | |||
@@ -379,6 +379,12 @@ int event__process_mmap(event_t *self, struct perf_session *session) | |||
379 | 379 | ||
380 | session->vmlinux_maps[MAP__FUNCTION]->start = self->mmap.start; | 380 | session->vmlinux_maps[MAP__FUNCTION]->start = self->mmap.start; |
381 | session->vmlinux_maps[MAP__FUNCTION]->end = self->mmap.start + self->mmap.len; | 381 | session->vmlinux_maps[MAP__FUNCTION]->end = self->mmap.start + self->mmap.len; |
382 | /* | ||
383 | * Be a bit paranoid here, some perf.data file came with | ||
384 | * a zero sized synthesized MMAP event for the kernel. | ||
385 | */ | ||
386 | if (session->vmlinux_maps[MAP__FUNCTION]->end == 0) | ||
387 | session->vmlinux_maps[MAP__FUNCTION]->end = ~0UL; | ||
382 | 388 | ||
383 | perf_session__set_kallsyms_ref_reloc_sym(session, symbol_name, | 389 | perf_session__set_kallsyms_ref_reloc_sym(session, symbol_name, |
384 | self->mmap.pgoff); | 390 | self->mmap.pgoff); |