Re: [RFC v2 6/7] perf: add api for pmus to write to AUX space
From: Peter Zijlstra
Date: Tue Jun 24 2014 - 13:27:37 EST
On Wed, Jun 11, 2014 at 06:41:49PM +0300, Alexander Shishkin wrote:
> +void perf_aux_output_end(struct perf_output_handle *handle, unsigned long size,
> + bool truncated)
> +{
> + struct ring_buffer *rb = handle->rb;
> + unsigned long aux_head;
> +
> + aux_head = local_read(&rb->aux_head);
> + local_add(size, &rb->aux_head);
> +
> + rb->user_page->aux_head = local_read(&rb->aux_head);
> + smp_wmb();
> +
> + perf_output_wakeup(handle);
> + handle->event = NULL;
> +
> + ring_buffer_put(rb);
> +}
This thing is distinctly less complex than perf_output_put_handle().. ?
Attachment:
pgpGlpxUyj1dU.pgp
Description: PGP signature