diff options
| author | Stephane Eranian <[email protected]> | 2010-02-01 12:50:01 +0000 |
|---|---|---|
| committer | Ingo Molnar <[email protected]> | 2010-02-04 08:59:50 +0000 |
| commit | 447a194b393f32699607fd99617a40abd6a95114 (patch) | |
| tree | 7d202a6ad8f80c913a4e3d439eedf5ba0abbbf39 /tools/perf/util/scripting-engines/trace-event-perl.c | |
| parent | bitops: Ensure the compile time HWEIGHT is only used for such (diff) | |
| download | kernel-447a194b393f32699607fd99617a40abd6a95114.tar.gz kernel-447a194b393f32699607fd99617a40abd6a95114.zip | |
perf_events, x86: Fix bug in hw_perf_enable()
We cannot assume that because hwc->idx == assign[i], we can avoid
reprogramming the counter in hw_perf_enable().
The event may have been scheduled out and another event may have been
programmed into this counter. Thus, we need a more robust way of
verifying if the counter still contains config/data related to an event.
This patch adds a generation number to each counter on each cpu. Using
this mechanism we can verify reliabilty whether the content of a counter
corresponds to an event.
Signed-off-by: Stephane Eranian <[email protected]>
Signed-off-by: Peter Zijlstra <[email protected]>
Cc: Mike Galbraith <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Arnaldo Carvalho de Melo <[email protected]>
Cc: Frederic Weisbecker <[email protected]>
LKML-Reference: <[email protected]>
Signed-off-by: Ingo Molnar <[email protected]>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-perl.c')
0 files changed, 0 insertions, 0 deletions
