lkml.org 
[lkml]   [2021]   [Oct]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    Date
    SubjectRe: [RFC][PATCH] rcu: Use typeof(p) instead of typeof(*p) *
    On Tue, Oct 5, 2021 at 12:40 PM Steven Rostedt <rostedt@goodmis.org> wrote:
    >
    > I may try it, because exposing the structure I want to hide, is pulling out
    > a lot of other crap with it :-p

    One option is just "don't do rcu_access of a pointer that you're not
    supposed to touch in a file that isn't supposed to touch it".

    IOW, why are you doing that

    pid_list = rcu_dereference_sched(tr->function_pids);

    in a place that isn't supposed to look at the pid_list in the first place?

    Yeah, yeah, I see how you just pass it to trace_ignore_this_task() as
    an argument, but maybe the real fix is to just pass that trace_array
    pointer instead?

    IOW, if you want to keep that structure private, maybe you really just
    shouldn't have non-private users of it randomly doing RCU lookups of
    it?

    Linus

    \
     
     \ /
      Last update: 2021-10-05 21:47    [W:2.446 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site