lkml.org 
[lkml]   [2019]   [May]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [GIT PULL] tracing: Updates for 5.2
On Wed, 15 May 2019 16:31:34 -0700
Linus Torvalds <torvalds@linux-foundation.org> wrote:

> On Wed, May 15, 2019 at 4:29 PM Linus Torvalds
> <torvalds@linux-foundation.org> wrote:
> >
> > One option is to just rewrite it something like
> >
> > const unsigned int offset = offsetof(struct trace_iterator, seq);
> > memset(offset+(void *)&iter, 0, sizeof(iter) - offset);
>
> Side note: make it a well-named helper function, since
> "ftrace_dump_buf()" does this too in kernel/trace/trace_kdb.c, and

Good point, as they just cut and pasted some of this code.

I like the helper function, as it means I don't need to add the sub
part, as the function would be more contained.

> gets the exact same warning.
>

I can do this, but it needs testing and all that before sending to you,
and may not make the merge window. Is that fine?

-- Steve

\
 
 \ /
  Last update: 2019-05-16 03:48    [W:0.061 / U:0.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site