linux/arch
Stephane Eranian 1261a02a0c perf_events, x86: Fix validate_event bug
The validate_event() was failing on valid event combinations. The
function was assuming that if x86_schedule_event() returned 0, it
meant error. But x86_schedule_event() returns the counter index and
0 is a perfectly valid value. An error is returned if the function
returns a negative value.

Furthermore, validate_event() was also failing for event groups
because the event->pmu was not set until after
hw_perf_event_init().

Signed-off-by: Stephane Eranian <eranian@google.com>
Cc: peterz@infradead.org
Cc: paulus@samba.org
Cc: perfmon2-devel@lists.sourceforge.net
Cc: eranian@gmail.com
LKML-Reference: <4b0bdf36.1818d00a.07cc.25ae@mx.google.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
--
 arch/x86/kernel/cpu/perf_event.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
2009-11-24 19:23:48 +01:00
..
alpha alpha: move THREAD_SIZE definition outside #ifndef ASSEMBLY 2009-11-12 07:25:56 -08:00
arm Merge branch 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6 2009-11-12 14:57:15 -08:00
avr32 at91: at91sam9g45 family: identify several chip versions 2009-11-03 18:42:31 +01:00
blackfin
cris
frv frv: fix check on unsigned in do_signal() 2009-10-29 07:39:32 -07:00
h8300
ia64 Revert "[IA64] fix percpu warnings" 2009-11-02 09:23:08 -08:00
m32r m32r: fix arch/m32r/boot/compressed/Makefile 2009-11-09 09:00:50 +09:00
m68k tty: Mark generic_serial users as BROKEN 2009-10-30 14:43:12 -07:00
m68knommu
microblaze
mips MIPS: O32: Fix ppoll 2009-11-02 12:00:08 +01:00
mn10300
parisc
powerpc Merge branches 'perf/powerpc' and 'perf/bench' into perf/core 2009-11-15 09:51:24 +01:00
s390 Merge commit 'v2.6.32-rc6' into perf/core 2009-11-04 11:59:45 +01:00
score
sh sh: Replace old style lock initializer 2009-11-09 10:47:40 +09:00
sparc sparc: Move of_set_property_mutex acquisition outside of devtree_lock grab. 2009-11-08 17:41:20 -08:00
um
x86 perf_events, x86: Fix validate_event bug 2009-11-24 19:23:48 +01:00
xtensa
.gitignore
Kconfig hw-breakpoints: Rewrite the hw-breakpoints layer on top of perf events 2009-11-08 15:34:42 +01:00