diff options
author | Peter Zijlstra <peterz@infradead.org> | 2016-04-04 10:02:08 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2016-04-13 05:56:36 -0400 |
commit | 31d50c551e30923b86a1b5b420920dd1927fa63b (patch) | |
tree | e19cc03a21b469ed946a23ee94f2c54192b0dc68 | |
parent | e465de1cd5e1759e40f077bac287de60d56ad06c (diff) |
perf/x86/amd/uncore: Do not register a task ctx for uncore PMUs
The new sanity check introduced by:
26657848502b ("perf/core: Verify we have a single perf_hw_context PMU")
... triggered on the AMD uncore driver.
Uncore PMUs are per node, they cannot have per-task counters. Fix it.
Reported-by: Borislav Petkov <bp@suse.de>
Reported-by: Ingo Molnar <mingo@kernel.org>
Tested-by: Borislav Petkov <bp@suse.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: acme@redhat.com
Cc: alexander.shishkin@linux.intel.com
Cc: eranian@google.com
Cc: jolsa@redhat.com
Cc: linux-tip-commits@vger.kernel.org
Cc: vincent.weaver@maine.edu
Link: http://lkml.kernel.org/r/20160404140208.GA3448@twins.programming.kicks-ass.net
Signed-off-by: Ingo Molnar <mingo@kernel.org>
-rw-r--r-- | arch/x86/events/amd/uncore.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/events/amd/uncore.c b/arch/x86/events/amd/uncore.c index 3db9569e658c..98ac57381bf9 100644 --- a/arch/x86/events/amd/uncore.c +++ b/arch/x86/events/amd/uncore.c | |||
@@ -263,6 +263,7 @@ static const struct attribute_group *amd_uncore_attr_groups[] = { | |||
263 | }; | 263 | }; |
264 | 264 | ||
265 | static struct pmu amd_nb_pmu = { | 265 | static struct pmu amd_nb_pmu = { |
266 | .task_ctx_nr = perf_invalid_context, | ||
266 | .attr_groups = amd_uncore_attr_groups, | 267 | .attr_groups = amd_uncore_attr_groups, |
267 | .name = "amd_nb", | 268 | .name = "amd_nb", |
268 | .event_init = amd_uncore_event_init, | 269 | .event_init = amd_uncore_event_init, |
@@ -274,6 +275,7 @@ static struct pmu amd_nb_pmu = { | |||
274 | }; | 275 | }; |
275 | 276 | ||
276 | static struct pmu amd_l2_pmu = { | 277 | static struct pmu amd_l2_pmu = { |
278 | .task_ctx_nr = perf_invalid_context, | ||
277 | .attr_groups = amd_uncore_attr_groups, | 279 | .attr_groups = amd_uncore_attr_groups, |
278 | .name = "amd_l2", | 280 | .name = "amd_l2", |
279 | .event_init = amd_uncore_event_init, | 281 | .event_init = amd_uncore_event_init, |