OSDN Git Service

Revert "perf/core: Fix endless multiplex timer"
authorGreg Kroah-Hartman <gregkh@google.com>
Wed, 16 Jun 2021 11:01:12 +0000 (13:01 +0200)
committerGreg Kroah-Hartman <gregkh@google.com>
Wed, 16 Jun 2021 16:32:12 +0000 (18:32 +0200)
This reverts commit 2cdbfd656720 ("perf/core: Fix endless multiplex
timer") as it is not needed because we reverted 0b4c9255a1d0
("perf/cgroups: Don't rotate events for cgroups unnecessarily") earlier
as it broke the ABI.

This also fixes the build breakage caused by the above commit being in
the tree and us reverting the original change.

Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I640225fb5db8f81fdf2011cabeb593c6d9f066b7

kernel/events/core.c

index 30cceb3..9237681 100644 (file)
@@ -2086,7 +2086,6 @@ __perf_remove_from_context(struct perf_event *event,
 
        if (!ctx->nr_events && ctx->is_active) {
                ctx->is_active = 0;
-               ctx->rotate_necessary = 0;
                if (ctx->task) {
                        WARN_ON_ONCE(cpuctx->task_ctx != ctx);
                        cpuctx->task_ctx = NULL;
@@ -2962,13 +2961,6 @@ static void ctx_sched_out(struct perf_event_context *ctx,
        if (is_active & EVENT_FLEXIBLE) {
                list_for_each_entry_safe(event, tmp, &ctx->flexible_active, active_list)
                        group_sched_out(event, cpuctx, ctx);
-
-               /*
-                * Since we cleared EVENT_FLEXIBLE, also clear
-                * rotate_necessary, is will be reset by
-                * ctx_flexible_sched_in() when needed.
-                */
-               ctx->rotate_necessary = 0;
        }
        perf_pmu_enable(ctx->pmu);
 }