From: Ingo Molnar <mingo@kernel.org>
To: Stephane Eranian <eranian@google.com>
Cc: linux-kernel@vger.kernel.org, bitbucket@online.de,
acme@redhat.com, peterz@infradead.org, mingo@elte.hu
Subject: Re: [PATCH] perf tools: fix missing default initialization for tool->mmap2
Date: Tue, 8 Oct 2013 13:59:29 +0200 [thread overview]
Message-ID: <20131008115929.GA2303@gmail.com> (raw)
In-Reply-To: <20131008105016.GA2446@quad>
* Stephane Eranian <eranian@google.com> wrote:
>
> This patch fixes a SEGFAULT bug with perf sched
> related to the new MMAP2 record type. There was
> a missing default initialization for the tool->mmap2
> pointer in perf_tool__fill_defaults().
>
> Reproducer:
> # perf sched record -- sleep 1
> # perf sched lat
>
> Reported-by: Mike Galbraith <bitbucket@online.de>
> Signed-off-by: Stephane Eranian <eranian@google.com>
> --
>
> diff --git a/tools/perf/util/session.c b/tools/perf/util/session.c
> index 211b325..8415c54 100644
> --- a/tools/perf/util/session.c
> +++ b/tools/perf/util/session.c
> @@ -256,6 +256,8 @@ void perf_tool__fill_defaults(struct perf_tool *tool)
> tool->sample = process_event_sample_stub;
> if (tool->mmap == NULL)
> tool->mmap = process_event_stub;
> + if (tool->mmap2 == NULL)
> + tool->mmap2 = process_event_stub;
> if (tool->comm == NULL)
> tool->comm = process_event_stub;
> if (tool->fork == NULL)
I think it's already fixed in tip:perf/urgent:
6adb0b0ae26f perf tools: Add default handler for mmap2 events
Thanks,
Ingo
next prev parent reply other threads:[~2013-10-08 11:59 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-08 10:50 [PATCH] perf tools: fix missing default initialization for tool->mmap2 Stephane Eranian
2013-10-08 11:59 ` Ingo Molnar [this message]
2013-10-08 12:02 ` Stephane Eranian
2013-10-08 12:28 ` Arnaldo Carvalho de Melo
2013-10-08 12:46 ` Stephane Eranian
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131008115929.GA2303@gmail.com \
--to=mingo@kernel.org \
--cc=acme@redhat.com \
--cc=bitbucket@online.de \
--cc=eranian@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.