Re: [Patch v2 1/4] perf/x86/intel: Clear stale ACR mask before updating new mask

Andi Kleen
2026-04-21T22:29:55Z

> diff --git a/arch/x86/events/intel/core.c b/arch/x86/events/intel/core.c
> index 4768236c054b..774ae9a4eeaf 100644
> --- a/arch/x86/events/intel/core.c
> +++ b/arch/x86/events/intel/core.c
> @@ -3334,6 +3334,12 @@ static void intel_pmu_acr_late_setup(struct cpu_hw_events *cpuc)
> struct perf_event *event, *leader;
> int i, j, idx;
>
> + /* Clear stale ACR mask first. */
> + for (i = 0; i < cpuc->n_events; i++) {
> + event = cpuc->event_list[i];
> + event->hw.config1 = 0;
> + }

Are you sure nothing else could be using config1?

In principle ACR events can be used with some config1 setting.

-Andi