lkml.org 
[lkml]   [2009]   [Nov]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: linux-next: percpu tree build warning
    Date
    On Fri, 27 Nov 2009 04:11:28 pm Ingo Molnar wrote:
    >
    > * Rusty Russell <rusty@rustcorp.com.au> wrote:
    >
    > > On Thu, 26 Nov 2009 12:10:58 am Ingo Molnar wrote:
    > > > While a percpu variable is defined and used in completely different
    > > > ways:
    > > >
    > > > DEFINE_PER_CPU(unsigned long, dr7);
    > > >
    > > > and is used via:
    > > >
    > > > __get_cpu_var(dr7); [[Fixed -- RR]]
    > >
    > > The entire point of Tejun's per-cpu work is that &dr7 is now valid. A
    > > per-cpu pointer as if it were allocated by the dynamic per-cpu
    > > allocator.
    > >
    > > Your arguments are fine, but out-of-date.
    >
    > But allowing &dr7 is outright dangerous - and not particularly clean
    > either.

    That's foolish. We can now have generic per-cpu function for counters
    and the like.

    > Nothing tells us that it's a percpu variable

    __percpu. Again, I'm explaining what you should already know before sending
    email about this stuff.

    > and it blends into the
    > regular namespace while most of the operators on it are special
    > (__get_cpu_var(), per_cpu(), __this_cpu(), etc.).

    OK, you convince Linus to change __user vars to use a prefix. Then I'll
    agree that per_cpu_## is more kernely.

    Stupidest debate ever.
    Rusty.


    \
     
     \ /
      Last update: 2009-11-28 10:55    [W:0.022 / U:1.132 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site