Re: [PATCH 1/4] tools lib traceevent: Add state member to structtrace_seq

From: Jiri Olsa
Date: Mon Jan 06 2014 - 09:38:56 EST


On Mon, Jan 06, 2014 at 04:44:18PM +0900, Namhyung Kim wrote:

SNIP

> >> + (s)->state = TRACE_SEQ__BUFFER_POISONED; \
> >
> > So unless we use trace_seq_do_printf we dont have any
> > notification that this went wrong..?
>
> Right.
>
> >
> > How about use some sort of WARN_ONCE any time the state
> > is set != GOOD ?
>
> I'm not sure what's the right thing to do for that case. Printing a
> warning message might disturb user's output since it can be in a middle
> of some (other) processing and she doesn't want to print anything during
> the processing for some reason.
>
> I just thought that it's not so important to print message so keeps the
> error internally until it gets printed. But I can be wrong as usual...

I think that if she manages to get one of those errors
the perf would fail soon anyway.. so it feels better
to print it out immediately.

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