diff options
author | Jiri Olsa <jolsa@redhat.com> | 2014-09-12 11:18:28 (GMT) |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2014-09-24 12:48:13 (GMT) |
commit | 802c8a61d4c9c794db863dcabb0006ab001a651b (patch) | |
tree | 9cc29310d921d14eff91fbf86c652f28a5a37372 /kernel | |
parent | 1929def9e609d1a8cdb1626d85eda3da66921a7d (diff) | |
download | linux-802c8a61d4c9c794db863dcabb0006ab001a651b.tar.xz |
Revert "perf: Do not allow optimized switch for non-cloned events"
This reverts commit 1f9a7268c67f0290837aada443d28fd953ddca90.
With the fix of the initial state for the cloned event we now correctly
handle the error described in:
1f9a7268c67f perf: Do not allow optimized switch for non-cloned events
so we can revert it.
I made an automated test for this, but its not suitable for automated
perf tests framework. It needs to be customized for each machine (the
more cpu the higher numbers for GROUPS/WORKERS/BYTES) and it could take
longer time to hit the issue.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Stephane Eranian <eranian@google.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/r/20140910143535.GD2409@krava.brq.redhat.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/events/core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/events/core.c b/kernel/events/core.c index 132524c..b164cb0 100644 --- a/kernel/events/core.c +++ b/kernel/events/core.c @@ -2375,7 +2375,7 @@ static void perf_event_context_sched_out(struct task_struct *task, int ctxn, next_parent = rcu_dereference(next_ctx->parent_ctx); /* If neither context have a parent context; they cannot be clones. */ - if (!parent || !next_parent) + if (!parent && !next_parent) goto unlock; if (next_parent == ctx || next_ctx == parent || next_parent == parent) { |