[lkml]   [1997]   [Sep]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectTwo bugs in kernel time code

    Ulrich> There's a very old bug in the kernel that rarely occurs (who's
    Ulrich> using NTP?): The code to update the CMOS clock does not consider
    Ulrich> the hour field. I had no clever idea to fix it, so I simply added
    Ulrich> a message to log the problem (well, a part of it).

    Oh, no, please... If you have no clever idea to fix it -- a log message every
    11 minutes ? This behaviour is _intentional_ -- I have no idea about the time
    zone the RTC is running on, so hours are untouched. No one from a half-hour
    or fifteen-minute time zone has complained yet :-|. A semi-clever approach
    would be to watch warp_time() from outside and add the kernel time zone

    Ulrich> In adjtimex() several parameters were not checked, making it
    Ulrich> possibly to pass invalid values to the kernel. Also the plain old
    Ulrich> adjtim() was dependent on the time_status & STA_PLL, which should
    Ulrich> be completely independent of adjtimex() (ntp_adjtime).

    Ulrich> Especially it was allowed to change the read-only bits of
    Ulrich> time_status...

    This however is a bug. Classic adjtime() shouldn't mess with the KPLL bits or
    at least set them to a defined state. Please note that use of adjtime() and
    ntp_adjtime() _*IS*_ exclusive for practical reasons. Note that adjtime() is
    _not_ limited to half a second !

    Ulrich> The function now even returns TIME_ERROR if the flags in
    Ulrich> time_state indicate an error condition.

    You have read RFC-1589 before doing modifications, haven't You ?

    Ulrich> It should go into 2.1 as well I guess...

    Please, work these suggestions into your patch, and maybe You can provide a
    diff -Bub next time if You re-indent things ? TIA

    Thanks a lot for your attention and work !


     \ /
      Last update: 2005-03-22 13:40    [W:0.019 / U:57.140 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site