aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-09-19 13:31:36 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-09-19 13:31:36 -0400
commit598a0c7d0932e385486b173768f03d95bf5507c8 (patch)
treed528410bffc0297c205b55dbb2b4a012243089d7 /kernel
parent7a5e87867e9fe043c3067a864124caf2b8e7fb99 (diff)
parent3577af70a2ce4853d58e57d832e687d739281479 (diff)
Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull perf fixes from Ingo Molnar: "Two kernel side fixes: a kprobes fix and a perf_remove_from_context() fix (which does not yet fix the migration bug which is WIP)" * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: perf: Fix a race condition in perf_remove_from_context() kprobes/x86: Free 'optinsn' cache when range check fails
Diffstat (limited to 'kernel')
-rw-r--r--kernel/events/core.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/kernel/events/core.c b/kernel/events/core.c
index f9c1ed002dbc..d640a8b4dcbc 100644
--- a/kernel/events/core.c
+++ b/kernel/events/core.c
@@ -1524,6 +1524,11 @@ retry:
1524 */ 1524 */
1525 if (ctx->is_active) { 1525 if (ctx->is_active) {
1526 raw_spin_unlock_irq(&ctx->lock); 1526 raw_spin_unlock_irq(&ctx->lock);
1527 /*
1528 * Reload the task pointer, it might have been changed by
1529 * a concurrent perf_event_context_sched_out().
1530 */
1531 task = ctx->task;
1527 goto retry; 1532 goto retry;
1528 } 1533 }
1529 1534
@@ -1967,6 +1972,11 @@ retry:
1967 */ 1972 */
1968 if (ctx->is_active) { 1973 if (ctx->is_active) {
1969 raw_spin_unlock_irq(&ctx->lock); 1974 raw_spin_unlock_irq(&ctx->lock);
1975 /*
1976 * Reload the task pointer, it might have been changed by
1977 * a concurrent perf_event_context_sched_out().
1978 */
1979 task = ctx->task;
1970 goto retry; 1980 goto retry;
1971 } 1981 }
1972 1982