aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorPeter Zijlstra <peterz@infradead.org>2009-12-15 13:43:11 -0500
committerIngo Molnar <mingo@elte.hu>2009-12-15 14:12:20 -0500
commitf13c12c634e124d5d31f912b969d542a016d6105 (patch)
treebbb5796189ba8c2755cc14880c2216862c2fc540 /kernel
parentcdccc69003388665e1463003f0488cf8ce9cf9e8 (diff)
perf_events: Fix perf_event_attr layout
The miss-alignment of bp_addr created a 32bit hole, causing different structure packings on 32 and 64 bit machines. Fix that by moving __reserve_2 into that hole. Further, remove the useless struct and redundant __bp_reserve muck. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> LKML-Reference: <1260902591.8023.781.camel@laptop> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/perf_event.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/perf_event.c b/kernel/perf_event.c
index 8823b088518..0dd8e5d02c6 100644
--- a/kernel/perf_event.c
+++ b/kernel/perf_event.c
@@ -4564,7 +4564,7 @@ static int perf_copy_attr(struct perf_event_attr __user *uattr,
4564 if (attr->type >= PERF_TYPE_MAX) 4564 if (attr->type >= PERF_TYPE_MAX)
4565 return -EINVAL; 4565 return -EINVAL;
4566 4566
4567 if (attr->__reserved_1 || attr->__reserved_2 || attr->__reserved_3) 4567 if (attr->__reserved_1 || attr->__reserved_2)
4568 return -EINVAL; 4568 return -EINVAL;
4569 4569
4570 if (attr->sample_type & ~(PERF_SAMPLE_MAX-1)) 4570 if (attr->sample_type & ~(PERF_SAMPLE_MAX-1))