Re: [PATCH 1/3] tracing: add __print_flags for events

From: Steven Rostedt
Date: Wed May 20 2009 - 18:13:50 EST



On Mon, 18 May 2009, Christoph Hellwig wrote:
> Some small comments:
>
> - __print_flags might be a little to generic. What about trace_print_flags?

The __print_flags is not a macro nor a function. It is similar to
__field() and __array() and __string(). It is a place holder that will be
overriden by the ftrace.h magic.

I'll keep it as __print_flags since it follows format with the other tags.

> - some documentation would help. I can submit a patch to the
> trave_events sample module to make use of it once this patch is
> merged.
> - Maybe passing an array instead of a list of flag/value pairs would be
> a tad cleaner? That would get rid of all the varargs mess and allow
> to declare that array next to the flags so get less easily out of
> sync.

OK, this may even save space. By passing by parameters we must load all
the parameters before calling the function. Even though this is on the
print side, it is still bloated. I'll convert it to an array.

Thanks,

-- Steve

--
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/