Re: [PATCH 2/4] tools lib traceevent: Add options to plugins

From: Namhyung Kim
Date: Mon May 19 2014 - 22:15:38 EST


On Tue, May 20, 2014 at 2:06 AM, Steven Rostedt <rostedt@xxxxxxxxxxx> wrote:
> On Mon, 2014-05-19 at 23:29 +0900, Namhyung Kim wrote:
>> 2014-05-16 (ê), 10:02 -0400, Steven Rostedt:

>> > -struct plugin_option {
>> > - struct plugin_option *next;
>> > +struct pevent_plugin_option {
>> > + struct pevent_plugin_option *next;
>>
>> Hmm.. this name change reminds me that it might be better if this plugin
>> and option list belong to a pevent..
>
> Yeah, eventually, but for now I want to try to sync what I have in
> trace-cmd with what is here in libtraceevent. At least to save history.
> Then we can modify it to be per pevent. For now, there's no users that
> need it per pevent. But that should definitely be changed before we push
> this out to distros.

Okay.


[SNIP]
>> > + free(name);
>> > + goto err;
>> > + }
>> > + list[count++] = name;
>> > + list[count] = NULL;
>> > + }
>> > + }
>> > + if (!count)
>> > + return NULL;
>> > + return list;
>>
>> Isn't it enough to simply return the list?
>
> Confused. Do you mean "Is it enough to simply return the list?"

I mean that it seems the 'list' is always NULL if the count is zero.


> BTW, Are you at LinuxCon Japan?

Nope, I'll be at LPC instead. :)

Thanks,
Namhyung
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/