]> git.baikalelectronics.ru Git - kernel.git/commit
perf_counter: Fix race in counter initialization
authorPeter Zijlstra <a.p.zijlstra@chello.nl>
Wed, 3 Jun 2009 12:01:36 +0000 (14:01 +0200)
committerIngo Molnar <mingo@elte.hu>
Wed, 3 Jun 2009 12:57:03 +0000 (14:57 +0200)
commit0dec3b7b04d2cefa910e850b8bd3c84dcf5ca22c
tree136e40a12a94653e8224d6c09d5384b4140e0532
parent53bb00daeacad8bed0cb25f0e998305051407e94
perf_counter: Fix race in counter initialization

We need the PID namespace and counter ID available when the
counter overflows and we need to generate a sample event.

[ Impact: fix kernel crash with high-frequency sampling ]

Reported-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: Marcelo Tosatti <mtosatti@redhat.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: John Kacur <jkacur@redhat.com>
LKML-Reference: <new-submission>
[ fixed a further crash and cleaned up the initialization a bit ]
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/perf_counter.c