diff options
Diffstat (limited to 'kernel/perf_event.c')
-rw-r--r-- | kernel/perf_event.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/kernel/perf_event.c b/kernel/perf_event.c index 40f8b07c5601..087025fe3ba1 100644 --- a/kernel/perf_event.c +++ b/kernel/perf_event.c | |||
@@ -1573,12 +1573,8 @@ static void rotate_ctx(struct perf_event_context *ctx) | |||
1573 | raw_spin_lock(&ctx->lock); | 1573 | raw_spin_lock(&ctx->lock); |
1574 | 1574 | ||
1575 | /* Rotate the first entry last of non-pinned groups */ | 1575 | /* Rotate the first entry last of non-pinned groups */ |
1576 | perf_disable(); | ||
1577 | |||
1578 | list_rotate_left(&ctx->flexible_groups); | 1576 | list_rotate_left(&ctx->flexible_groups); |
1579 | 1577 | ||
1580 | perf_enable(); | ||
1581 | |||
1582 | raw_spin_unlock(&ctx->lock); | 1578 | raw_spin_unlock(&ctx->lock); |
1583 | } | 1579 | } |
1584 | 1580 | ||
@@ -1593,6 +1589,8 @@ void perf_event_task_tick(struct task_struct *curr) | |||
1593 | cpuctx = &__get_cpu_var(perf_cpu_context); | 1589 | cpuctx = &__get_cpu_var(perf_cpu_context); |
1594 | ctx = curr->perf_event_ctxp; | 1590 | ctx = curr->perf_event_ctxp; |
1595 | 1591 | ||
1592 | perf_disable(); | ||
1593 | |||
1596 | perf_ctx_adjust_freq(&cpuctx->ctx); | 1594 | perf_ctx_adjust_freq(&cpuctx->ctx); |
1597 | if (ctx) | 1595 | if (ctx) |
1598 | perf_ctx_adjust_freq(ctx); | 1596 | perf_ctx_adjust_freq(ctx); |
@@ -1608,6 +1606,8 @@ void perf_event_task_tick(struct task_struct *curr) | |||
1608 | cpu_ctx_sched_in(cpuctx, EVENT_FLEXIBLE); | 1606 | cpu_ctx_sched_in(cpuctx, EVENT_FLEXIBLE); |
1609 | if (ctx) | 1607 | if (ctx) |
1610 | task_ctx_sched_in(curr, EVENT_FLEXIBLE); | 1608 | task_ctx_sched_in(curr, EVENT_FLEXIBLE); |
1609 | |||
1610 | perf_enable(); | ||
1611 | } | 1611 | } |
1612 | 1612 | ||
1613 | static int event_enable_on_exec(struct perf_event *event, | 1613 | static int event_enable_on_exec(struct perf_event *event, |