Re: Bug: Status/Summary of slashdot leap-second crash on new years2008-2009

From: Alan Cox
Date: Wed Jan 07 2009 - 09:16:20 EST


> > The RTC stores the CMOS time in MM DD YY HH:MM:SS format.
>
> Yes, which is perfect for mktime(), which knows about leap seconds and
> so produces the correct time_t.

mktime in the kernel has no knowledge of leap seconds whatsoever. Go read
kernel/time.c

> different understanding. I thought it was said that there's kernel
> support to handle the leap second flag in NTP's broadcasts, and that
> that was where the bug was.

All the kernel knows how to do is to slew time (in general) and to repeat
or remove one second. It has no knowledge of leap seconds and it doesn't
know how to convert between UTC/TAI/Unix Epoch etc

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/