[lkml]   [2005]   [Aug]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [OT] volatile keyword
    On Thu, 25 Aug 2005, Christopher Friesen wrote:

    > Vadim Lobanov wrote:
    > > I'm positive I'm doing something wrong here. In fact, I bet it's the
    > > volatile cast within the loop that's wrong; but I'm not sure how to do
    > > it correctly. Any help / pointers / discussion would be appreciated.
    > You need to cast is as dereferencing a volatile pointer.
    > Chris

    I figured it was something along these lines. In that case, is the
    following code (from kernel/posix-timers.c) really doing the right

    expires = timr->it_timer.expires;
    while ((volatile long) (timr->it_timer.expires) != expires);

    Seems it's casting the value, not the pointer.

    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-08-25 23:19    [W:0.040 / U:78.676 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site