[lkml]   [2002]   [Aug]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [patch 6/12] hold atomic kmaps across generic_file_read
    On Monday 12 August 2002 09:45, Rusty Russell wrote:
    > On Fri, 9 Aug 2002 18:33:09 -0700 (PDT)
    > Linus Torvalds <> wrote:
    > > repeat:
    > > kmap_atomic(..); // this increments preempt count
    > > nr = copy_from_user(..);
    > Please please please use a different name for "I know I'm not preemptible but
    > I can handle it" or a flag or something.
    > That leaves us with the possibility of a BUG() in the "normal" copy_to/from_user
    > for all those "I'm holding a spinlock while copying to userspace wheeee!" bugs.
    > Very common mistake for new kernel authors.

    That's the whole point of this: it's not a bug anymore. (It's a feature.)

    But agreed, a different name than preempt count would be nice, because it's
    evolving away from its original function. Is this a 'monitor'? (I don't
    think so.) Perhaps 'atomic_count' is more accurate.

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2005-03-22 13:27    [W:0.022 / U:59.672 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site