From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Thomas Richter <tmricht@linux.vnet.ibm.com>
Cc: brueckner@linux.vnet.ibm.com, zvonko.kosic@de.ibm.com,
linux-perf-users@vger.kernel.org
Subject: Re: [PATCH 2/2] perf record: wrong size in perf_record_mmap for last kernel module
Date: Wed, 2 Aug 2017 15:50:47 -0300 [thread overview]
Message-ID: <20170802185047.GL12201@kernel.org> (raw)
In-Reply-To: <20170724182007.GY4134@kernel.org>
Em Mon, Jul 24, 2017 at 03:20:07PM -0300, Arnaldo Carvalho de Melo escreveu:
> Em Mon, Jul 24, 2017 at 04:35:14PM +0200, Thomas Richter escreveu:
> > +++ b/tools/perf/util/machine.c
> > @@ -20,6 +20,7 @@
> > +#include <sys/user.h>
no need for this header, see below.
> > -static int machine__create_module(void *arg, const char *name, u64 start)
> > +static int machine__create_module(void *arg, const char *name, u64 start, u64 size)
> > {
> > @@ -1148,6 +1149,7 @@ static int machine__create_module(void *arg, const char *name, u64 start)
> > map = machine__findnew_module_map(machine, start, name);
> > if (map == NULL)
> > return -1;
> > + map->end = roundup(start + size, PAGE_SIZE);
We have the page_size variable, that gets its value at:
tools/perf/perf.c: page_size = sysconf(_SC_PAGE_SIZE);
always available, determined at run time.
Also, what is the reason for the roundup?
> > dso__kernel_module_get_build_id(map->dso, machine->root_dir);
- Arnaldo
next prev parent reply other threads:[~2017-08-02 18:50 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-24 14:35 [PATCH 1/2] perf report fix module symbol adjustment for s390x Thomas Richter
2017-07-24 14:35 ` [PATCH 2/2] perf record: wrong size in perf_record_mmap for last kernel module Thomas Richter
2017-07-24 18:20 ` Arnaldo Carvalho de Melo
2017-07-25 8:45 ` Thomas-Mich Richter
2017-08-02 18:50 ` Arnaldo Carvalho de Melo [this message]
2017-08-03 9:41 ` Thomas-Mich Richter
2017-08-04 17:06 ` Arnaldo Carvalho de Melo
2017-08-07 7:26 ` Thomas-Mich Richter
2017-08-07 16:05 ` Arnaldo Carvalho de Melo
2017-08-08 7:16 ` Thomas-Mich Richter
2017-07-25 6:58 ` Namhyung Kim
2017-07-25 8:26 ` Thomas-Mich Richter
2017-07-25 6:14 ` [PATCH 1/2] perf report fix module symbol adjustment for s390x Namhyung Kim
2017-07-25 8:49 ` Thomas-Mich Richter
2017-07-25 10:32 ` Namhyung Kim
2017-07-25 14:20 ` Arnaldo Carvalho de Melo
2017-08-02 11:25 ` Thomas-Mich Richter
2017-08-02 18:42 ` Arnaldo Carvalho de Melo
2017-08-03 9:37 ` Thomas-Mich Richter
2017-08-03 12:45 ` Arnaldo Carvalho de Melo
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=20170802185047.GL12201@kernel.org \
--to=acme@kernel.org \
--cc=brueckner@linux.vnet.ibm.com \
--cc=linux-perf-users@vger.kernel.org \
--cc=tmricht@linux.vnet.ibm.com \
--cc=zvonko.kosic@de.ibm.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).