perf/x86/intel: Add cross-HT counter exclusion infrastructure
authorMaria Dimakopoulou <maria.n.dimakopoulou@gmail.com>
Mon, 17 Nov 2014 19:06:57 +0000 (20:06 +0100)
committerIngo Molnar <mingo@kernel.org>
Thu, 2 Apr 2015 15:33:11 +0000 (17:33 +0200)
commit6f6539cad926f55d5eb6e79d05bbe99f0d54d56d
tree25b7ddb8abc3d567ddd108c9cc601a22ececd3bb
parent79cba822443a168c8f7f5b853d9c7225a6d5415e
perf/x86/intel: Add cross-HT counter exclusion infrastructure

This patch adds a new shared_regs style structure to the
per-cpu x86 state (cpuc). It is used to coordinate access
between counters which must be used with exclusion across
HyperThreads on Intel processors. This new struct is not
needed on each PMU, thus is is allocated on demand.

Signed-off-by: Maria Dimakopoulou <maria.n.dimakopoulou@gmail.com>
[peterz: spinlock_t -> raw_spinlock_t]
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Stephane Eranian <eranian@google.com>
Cc: bp@alien8.de
Cc: jolsa@redhat.com
Cc: kan.liang@intel.com
Link: http://lkml.kernel.org/r/1416251225-17721-6-git-send-email-eranian@google.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
arch/x86/kernel/cpu/perf_event.h
arch/x86/kernel/cpu/perf_event_intel.c