* [PATCH 1/2] perf tools: fix build for rbtree.c change
@ 2012-03-30 17:38 Andi Kleen
2012-03-30 17:38 ` [PATCH 2/2] perf tools: Fix record sample overlap check for callchains Andi Kleen
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Andi Kleen @ 2012-03-30 17:38 UTC (permalink / raw)
To: acme; +Cc: linux-kernel, Andi Kleen
From: Andi Kleen <ak@linux.intel.com>
rbtree.c in the main tree now includes linux/export.h, so this file
needs a stub too. This makes perf build again in mainline.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
---
tools/perf/util/include/linux/export.h | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
create mode 100644 tools/perf/util/include/linux/export.h
diff --git a/tools/perf/util/include/linux/export.h b/tools/perf/util/include/linux/export.h
new file mode 100644
index 0000000..493b181
--- /dev/null
+++ b/tools/perf/util/include/linux/export.h
@@ -0,0 +1 @@
+#include <linux/module.h>
--
1.7.7.6
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/2] perf tools: Fix record sample overlap check for callchains
2012-03-30 17:38 [PATCH 1/2] perf tools: fix build for rbtree.c change Andi Kleen
@ 2012-03-30 17:38 ` Andi Kleen
2012-03-30 21:03 ` David Ahern
2012-03-30 17:47 ` [PATCH 1/2] perf tools: fix build for rbtree.c change Josh Boyer
2012-03-30 20:58 ` Arnaldo Carvalho de Melo
2 siblings, 1 reply; 6+ messages in thread
From: Andi Kleen @ 2012-03-30 17:38 UTC (permalink / raw)
To: acme; +Cc: linux-kernel, Andi Kleen
From: Andi Kleen <ak@linux.intel.com>
perf record checks for buffer overflow, but checked for the wrong
size for callchains. callchains are 8 bytes each, not 1.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
---
tools/perf/util/evsel.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c
index f421f7c..90c0756 100644
--- a/tools/perf/util/evsel.c
+++ b/tools/perf/util/evsel.c
@@ -550,7 +550,7 @@ int perf_event__parse_sample(const union perf_event *event, u64 type,
data->callchain = (struct ip_callchain *)array;
- if (sample_overlap(event, array, data->callchain->nr))
+ if (sample_overlap(event, array, (1 + data->callchain->nr) * 8))
return -EFAULT;
array += 1 + data->callchain->nr;
--
1.7.7.6
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] perf tools: fix build for rbtree.c change
2012-03-30 17:38 [PATCH 1/2] perf tools: fix build for rbtree.c change Andi Kleen
2012-03-30 17:38 ` [PATCH 2/2] perf tools: Fix record sample overlap check for callchains Andi Kleen
@ 2012-03-30 17:47 ` Josh Boyer
2012-03-30 22:00 ` Arnaldo Carvalho de Melo
2012-03-30 20:58 ` Arnaldo Carvalho de Melo
2 siblings, 1 reply; 6+ messages in thread
From: Josh Boyer @ 2012-03-30 17:47 UTC (permalink / raw)
To: Andi Kleen; +Cc: acme, linux-kernel, Andi Kleen, Ingo Molnar
On Fri, Mar 30, 2012 at 1:38 PM, Andi Kleen <andi@firstfloor.org> wrote:
> From: Andi Kleen <ak@linux.intel.com>
>
> rbtree.c in the main tree now includes linux/export.h, so this file
> needs a stub too. This makes perf build again in mainline.
>
> Signed-off-by: Andi Kleen <ak@linux.intel.com>
http://git.kernel.org/?p=linux/kernel/git/tip/tip.git;a=commit;h=2c86bf172e550b4bf089ac7f0de3f6370e243842
Apparently 'perf-urgent-for-linus' isn't as urgent as it sounds?
josh
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] perf tools: fix build for rbtree.c change
2012-03-30 17:38 [PATCH 1/2] perf tools: fix build for rbtree.c change Andi Kleen
2012-03-30 17:38 ` [PATCH 2/2] perf tools: Fix record sample overlap check for callchains Andi Kleen
2012-03-30 17:47 ` [PATCH 1/2] perf tools: fix build for rbtree.c change Josh Boyer
@ 2012-03-30 20:58 ` Arnaldo Carvalho de Melo
2 siblings, 0 replies; 6+ messages in thread
From: Arnaldo Carvalho de Melo @ 2012-03-30 20:58 UTC (permalink / raw)
To: Andi Kleen; +Cc: linux-kernel, Andi Kleen
Em Fri, Mar 30, 2012 at 10:38:33AM -0700, Andi Kleen escreveu:
> From: Andi Kleen <ak@linux.intel.com>
>
> rbtree.c in the main tree now includes linux/export.h, so this file
> needs a stub too. This makes perf build again in mainline.
Thank you, this one got fixed already.
> Signed-off-by: Andi Kleen <ak@linux.intel.com>
> ---
> tools/perf/util/include/linux/export.h | 1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
> create mode 100644 tools/perf/util/include/linux/export.h
>
> diff --git a/tools/perf/util/include/linux/export.h b/tools/perf/util/include/linux/export.h
> new file mode 100644
> index 0000000..493b181
> --- /dev/null
> +++ b/tools/perf/util/include/linux/export.h
> @@ -0,0 +1 @@
> +#include <linux/module.h>
> --
> 1.7.7.6
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] perf tools: Fix record sample overlap check for callchains
2012-03-30 17:38 ` [PATCH 2/2] perf tools: Fix record sample overlap check for callchains Andi Kleen
@ 2012-03-30 21:03 ` David Ahern
0 siblings, 0 replies; 6+ messages in thread
From: David Ahern @ 2012-03-30 21:03 UTC (permalink / raw)
To: Andi Kleen; +Cc: acme, linux-kernel, Andi Kleen
On 3/30/12 11:38 AM, Andi Kleen wrote:
> From: Andi Kleen<ak@linux.intel.com>
>
> perf record checks for buffer overflow, but checked for the wrong
> size for callchains. callchains are 8 bytes each, not 1.
>
> Signed-off-by: Andi Kleen<ak@linux.intel.com>
> ---
> tools/perf/util/evsel.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c
> index f421f7c..90c0756 100644
> --- a/tools/perf/util/evsel.c
> +++ b/tools/perf/util/evsel.c
> @@ -550,7 +550,7 @@ int perf_event__parse_sample(const union perf_event *event, u64 type,
>
> data->callchain = (struct ip_callchain *)array;
>
> - if (sample_overlap(event, array, data->callchain->nr))
> + if (sample_overlap(event, array, (1 + data->callchain->nr) * 8))
sizeof(u64) rather than the magic 8?
David
> return -EFAULT;
>
> array += 1 + data->callchain->nr;
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] perf tools: fix build for rbtree.c change
2012-03-30 17:47 ` [PATCH 1/2] perf tools: fix build for rbtree.c change Josh Boyer
@ 2012-03-30 22:00 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 6+ messages in thread
From: Arnaldo Carvalho de Melo @ 2012-03-30 22:00 UTC (permalink / raw)
To: Josh Boyer; +Cc: Andi Kleen, linux-kernel, Andi Kleen, Ingo Molnar
Em Fri, Mar 30, 2012 at 01:47:53PM -0400, Josh Boyer escreveu:
> On Fri, Mar 30, 2012 at 1:38 PM, Andi Kleen <andi@firstfloor.org> wrote:
> > From: Andi Kleen <ak@linux.intel.com>
> >
> > rbtree.c in the main tree now includes linux/export.h, so this file
> > needs a stub too. This makes perf build again in mainline.
> >
> > Signed-off-by: Andi Kleen <ak@linux.intel.com>
>
> http://git.kernel.org/?p=linux/kernel/git/tip/tip.git;a=commit;h=2c86bf172e550b4bf089ac7f0de3f6370e243842
>
> Apparently 'perf-urgent-for-linus' isn't as urgent as it sounds?
There was a delay due to a resolution on getting rid of pre-generated
bison/flex files, but Ingo should expedite that pull request RSN.
- Arnaldo
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-03-30 22:00 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-30 17:38 [PATCH 1/2] perf tools: fix build for rbtree.c change Andi Kleen
2012-03-30 17:38 ` [PATCH 2/2] perf tools: Fix record sample overlap check for callchains Andi Kleen
2012-03-30 21:03 ` David Ahern
2012-03-30 17:47 ` [PATCH 1/2] perf tools: fix build for rbtree.c change Josh Boyer
2012-03-30 22:00 ` Arnaldo Carvalho de Melo
2012-03-30 20:58 ` Arnaldo Carvalho de Melo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox