Re: [PATCH] perf/aux: Properly launch pending disable flow
From: Yeoreum Yun
Date: Mon Jun 09 2025 - 11:01:16 EST
Hi Leo,
[...]
> --- a/kernel/events/ring_buffer.c
> +++ b/kernel/events/ring_buffer.c
> @@ -441,7 +441,7 @@ void *perf_aux_output_begin(struct perf_output_handle *handle,
> * store that will be enabled on successful return
> */
> if (!handle->size) { /* A, matches D */
> - event->pending_disable = smp_processor_id();
> + perf_event_disable_inatomic(handle->event);
> perf_output_wakeup(handle);
> WRITE_ONCE(rb->aux_nest, 0);
> goto err_put;
> @@ -526,7 +526,7 @@ void perf_aux_output_end(struct perf_output_handle *handle, unsigned long size)
>
> if (wakeup) {
> if (handle->aux_flags & PERF_AUX_FLAG_TRUNCATED)
> - handle->event->pending_disable = smp_processor_id();
> + perf_event_disable_inatomic(handle->event);
> perf_output_wakeup(handle);
> }
LGTM.
Reviewed-by: Yeoreum Yun <yeoreum.yun@xxxxxxx>
--
Sincerely,
Yeoreum Yun