lkml.org 
[lkml]   [2020]   [Jan]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v4 07/12] tracing: Add synth_event_trace() and related functions
On Wed, 29 Jan 2020 12:59:27 -0600
Tom Zanussi <zanussi@kernel.org> wrote:

> +static struct synth_field *find_synth_field(struct synth_event *event,
> + const char *field_name)
> +{
> + struct synth_field *field = NULL;
> + unsigned int i;
> +
> + for (i = 0; i < event->n_fields; i++) {
> + field = event->fields[i];
> + if (strcmp(field->name, field_name) == 0)
> + return field;
> + }
> +
> + return NULL;
> +}

Why duplicate all theses functions and not use them in the
synth_event_trace() directly?

-- Steve

\
 
 \ /
  Last update: 2020-01-29 22:09    [W:0.122 / U:0.572 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site