lkml.org 
[lkml]   [2023]   [Jan]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 5/8] perf/core: Set data->sample_flags in perf_prepare_sample()
On Thu, Jan 12, 2023 at 01:40:12PM -0800, Namhyung Kim wrote:

> --- a/kernel/events/core.c
> +++ b/kernel/events/core.c
> @@ -7053,6 +7053,14 @@ static void perf_aux_sample_output(struct perf_event *event,
> ring_buffer_put(rb);
> }
>
> +/*
> + * A set of common sample data types saved even for non-sample records
> + * when event->attr.sample_id_all is set.
> + */
> +#define PERF_SAMPLE_ID_ALL (PERF_SAMPLE_TID | PERF_SAMPLE_TIME | \
> + PERF_SAMPLE_CPU | PERF_SAMPLE_ID | \
> + PERF_SAMPLE_IDENTIFIER | PERF_SAMPLE_STREAM_ID)
> +


> __perf_event_header__init_id(header, data, event, filtered_sample_type);
> + data->sample_flags |= sample_type & PERF_SAMPLE_ID_ALL;

Why not update __perf_event_header__init_id() ?

\
 
 \ /
  Last update: 2023-03-26 23:39    [W:0.175 / U:0.496 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site