From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: David Ahern <dsahern@gmail.com>,
linux-kernel@vger.kernel.org, Namhyung Kim <namhyung@kernel.org>,
Jiri Olsa <jolsa@kernel.org>
Subject: Re: [PATCH] perf trace: Handle legacy syscalls
Date: Fri, 20 Mar 2015 12:44:35 -0300 [thread overview]
Message-ID: <20150320154435.GJ16485@kernel.org> (raw)
In-Reply-To: <20150320114011.4e25167c@gandalf.local.home>
Em Fri, Mar 20, 2015 at 11:40:11AM -0400, Steven Rostedt escreveu:
> On Fri, 20 Mar 2015 12:32:26 -0300
> Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> > Em Thu, Mar 19, 2015 at 12:36:21PM -0600, David Ahern escreveu:
> > > +++ b/tools/lib/traceevent/event-parse.c
> > > @@ -6228,15 +6228,20 @@ void pevent_ref(struct pevent *pevent)
> > > pevent->ref_count++;
> > > }
> > >
> > > +void free_format_field(struct format_field *field)
> > > +{
> > > + free(field->type);
> > > + free(field->name);
> > > + free(field);
> > > +}
> > > +
> > > static void free_format_fields(struct format_field *field)
> > > {
> > > struct format_field *next;
> > >
> > > while (field) {
> > > next = field->next;
> > > - free(field->type);
> > > - free(field->name);
> > > - free(field);
> > > + free_format_field(field);
> > > field = next;
> > > }
> > > }
> > > diff --git a/tools/lib/traceevent/event-parse.h b/tools/lib/traceevent/event-parse.h
> > > index 5b4efc062320..a548fac646f6 100644
> > > --- a/tools/lib/traceevent/event-parse.h
> > > +++ b/tools/lib/traceevent/event-parse.h
> > > @@ -619,6 +619,7 @@ enum pevent_errno pevent_parse_format(struct pevent *pevent,
> > > const char *buf,
> > > unsigned long size, const char *sys);
> > > void pevent_free_format(struct event_format *event);
> > > +void free_format_field(struct format_field *field);
>
> Can we make it "pevent_free_format_field" to keep consistency.
>
> > >
> > > void *pevent_get_field_raw(struct trace_seq *s, struct event_format *event,
> > > const char *name, struct pevent_record *record,
> > > diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
> > > index dcd950ef2fd7..5caeefeda48a 100644
> >
> >
> > Up to here we should have a separate patch, one that I would like to
> > have an Acked-by: Rostedt, ok?
>
> I'm fine with the change if the name of the function is updated.
Ok, so I'll put it in a separate patch, authored by David, with your
Acked-by, it may be useful at some point besides being used in the
libtraceevent internal free_format_fields() static function.
- Arnaldo
next prev parent reply other threads:[~2015-03-20 15:45 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-19 18:36 [PATCH] perf trace: Handle legacy syscalls David Ahern
2015-03-20 15:32 ` Arnaldo Carvalho de Melo
2015-03-20 15:40 ` Steven Rostedt
2015-03-20 15:44 ` Arnaldo Carvalho de Melo [this message]
2015-03-20 15:48 ` David Ahern
2015-03-20 15:48 ` David Ahern
2015-03-20 16:06 ` Arnaldo Carvalho de Melo
2015-03-20 16:12 ` David Ahern
2015-03-20 16:26 ` Arnaldo Carvalho de Melo
2015-03-20 16:30 ` David Ahern
2015-03-22 10:17 ` [tip:perf/core] tools lib traceevent: Add destructor for format_field tip-bot for David Ahern
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150320154435.GJ16485@kernel.org \
--to=acme@kernel.org \
--cc=dsahern@gmail.com \
--cc=jolsa@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=namhyung@kernel.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox