[lkml]   [2005]   [Oct]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: 2.6.14-rc4-rt7
    On Wed, 2005-10-26 at 21:07 -0400, Steven Rostedt wrote:
    > On Wed, 2005-10-26 at 17:45 -0700, john stultz wrote:
    > > Ok, I've reproduced the issue.
    > >
    > > However, running a clock_gettime(CLOCK_MONOTONIC) inconsistency check
    > > results in no failures, but triggers this code in the kernel.
    > >
    > > Looking at the code, these may be false positives. The bit that is
    > > complaining I believe Ingo added to get_monotonic_clock_ts() in
    > > kernel/time/timeofday.c. However I don't see any locking that
    > > serializes the writes the prev in the same order as the
    > > get_monotonic_clock_ts is called.
    > >
    > > I'm still digging and will send out some mail when I figure out whats
    > > wrong.
    > Hmm, I'm wondering if these are a false positive. Being a fully
    > preemptible kernel, we could be preempted between taking now and getting
    > prev, so the prev could be updated to a time after now and show a warp.
    > William and Rui, could you try this patch and see if you still get the
    > warnings. Although I doubt this is really the problem, since I can't
    > see how it would cause clusters of these messages.

    I don't know if that would really fix it, because ideally you want to
    read the prev_mono_time at the same point you calculate the time inside
    the read lock'ed critical section.

    The difficulty is then even if you do read the prev value in a
    serialized manner, you have to serialize the writes properly as well. So
    really you want to do all four operations (read prev, calculate time, do
    comparision, write prev) under a write lock.

    Again, I'm not totally sure about this, but even removing the part where
    it overwrites the ts pointer w/ the prev time, I do not see
    inconsistencies from userland.

    Also I'm not seeing clusters of messages. If you call
    clock_gettime(CLOCK_MONOTONIC,..) in a loop, you'll see tons of these

    The only odd part is the regularness of the errors. I'm seeing the ~5000
    ns deltas ~every ms. So there may be something going wrong, but I don't
    see it yet.


    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-10-27 03:24    [W:0.029 / U:52.280 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site