diff options
author | Ingo Molnar <mingo@kernel.org> | 2015-03-27 09:46:03 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2015-03-27 09:46:03 +0100 |
commit | 072e5a1cfabca7276744d24726e094d85721df5c (patch) | |
tree | c7237fa143f72273aa8a8179f741c24b9072001c /kernel/events | |
parent | 294fe0f52a44c6f207211de0686c369a961b5533 (diff) | |
parent | d525211f9d1be8b523ec7633f080f2116f5ea536 (diff) | |
download | linux-072e5a1cfabca7276744d24726e094d85721df5c.tar.bz2 |
Merge branch 'perf/urgent' into perf/core, to pick up fixes and to refresh the tree
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/events')
-rw-r--r-- | kernel/events/core.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/kernel/events/core.c b/kernel/events/core.c index 8bb20cc39a92..9a5f339a0e2d 100644 --- a/kernel/events/core.c +++ b/kernel/events/core.c @@ -3610,7 +3610,7 @@ static void put_event(struct perf_event *event) ctx = perf_event_ctx_lock_nested(event, SINGLE_DEPTH_NESTING); WARN_ON_ONCE(ctx->parent_ctx); perf_remove_from_context(event, true); - mutex_unlock(&ctx->mutex); + perf_event_ctx_unlock(event, ctx); _free_event(event); } @@ -4593,6 +4593,13 @@ static void perf_pending_event(struct irq_work *entry) { struct perf_event *event = container_of(entry, struct perf_event, pending); + int rctx; + + rctx = perf_swevent_get_recursion_context(); + /* + * If we 'fail' here, that's OK, it means recursion is already disabled + * and we won't recurse 'further'. + */ if (event->pending_disable) { event->pending_disable = 0; @@ -4603,6 +4610,9 @@ static void perf_pending_event(struct irq_work *entry) event->pending_wakeup = 0; perf_event_wakeup(event); } + + if (rctx >= 0) + perf_swevent_put_recursion_context(rctx); } /* |