lkml.org 
[lkml]   [2008]   [Nov]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/1] ftrace: fix wrong pos computing when read buffer has been fulfilled.

On Tue, 18 Nov 2008, walimis wrote:
> On Tue, Nov 18, 2008 at 09:36:07AM -0500, Steven Rostedt wrote:
> >>
> >> fix:
> >>
> >> Through checking return value of seq_printf, if less than 0, we know
> >> this function doesn't be printed. Then we decrease position to force
> >> this function to be printed next time, in next read buffer.
> >
> >A lot of the code for seq files I cut and paste from other places that I
> >have written it. The seq files always confuse me, so I like to use stuff
> >that worked before. Some of the things that walimis fixed were not needed
> >for this file, and was overkill.

> It also confuse me a lot. I also checked all places using seq files in
> trace/ftrace code, to see whether there are similar problem.
> - trace.c: in s_start() it force pos to decrease one such as:
> l = *pos - 1;
> so it works well.
> - trace_stack.c: t_start, in almost all cases, can be only called
> once, so we don't see the error. But I wonder whether it still works
> well if output message exceeds the size of seq file buffer and call
> t_start twice. If needed, I can test it.
> - trace_branch.c : the same with above.
>

If you can find a bug, then by all means, fix it ;-)

Thanks,

-- Steve



\
 
 \ /
  Last update: 2008-11-18 16:35    [W:0.041 / U:0.792 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site