summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kernel/perf_event.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/kernel/perf_event.c b/kernel/perf_event.c
index 6d7eef5f3c41..27332e5f51a7 100644
--- a/kernel/perf_event.c
+++ b/kernel/perf_event.c
@@ -6269,14 +6269,13 @@ static void perf_event_exit_cpu_context(int cpu)
idx = srcu_read_lock(&pmus_srcu);
list_for_each_entry_rcu(pmu, &pmus, entry) {
- ctx = &this_cpu_ptr(pmu->pmu_cpu_context)->ctx;
+ ctx = &per_cpu_ptr(pmu->pmu_cpu_context, cpu)->ctx;
mutex_lock(&ctx->mutex);
smp_call_function_single(cpu, __perf_event_exit_context, ctx, 1);
mutex_unlock(&ctx->mutex);
}
srcu_read_unlock(&pmus_srcu, idx);
-
}
static void perf_event_exit_cpu(int cpu)
OpenPOWER on IntegriCloud