Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 13 Sep 2011 10:24:55 -0700
From:      Chuck Swiger <cswiger@mac.com>
To:        Brett Glass <brett@lariat.net>
Cc:        FreeBSD Questions List <questions@freebsd.org>
Subject:   Re: Negative ping times with FreeBSD 8.1-RELEASE on older Celeron system
Message-ID:  <80A6E751-9A62-4E58-A0DD-707B39C006DB@mac.com>
In-Reply-To: <201109131649.KAA00227@lariat.net>
References:  <201109122350.RAA21916@lariat.net> <F06D137D-F364-46B2-9458-6882B543B3A6@mac.com> <201109130443.WAA23650@lariat.net> <CA%2BtpaK2VVdue4MsJpzUxEQABDk1pFVWy_0=CqSEaRifM8CKX5Q@mail.gmail.com> <201109131021.EAA26090@lariat.net> <20110913151650.GF9801@dan.emsphone.com> <201109131649.KAA00227@lariat.net>

next in thread | previous in thread | raw e-mail | index | archive | help
[ ...combining two emails... ]

On Sep 13, 2011, at 9:49 AM, Brett Glass wrote:
> If that's indeed the case, the kernel must be doing the math wrong.

While there have undoubtedly have been kernel bugs with timekeeping (and there may be more still present), it's not uncommon for hardware issues to cause one or more of the available time sources to be broken.

On a good day, the clock source is broken obviously enough that the kernel notices it during testing during boot and gives it a negative quality score.  Other times, the clock becomes broken only after the box suspends and resumes from an ACPI S# state, or does frequency changes for power/thermal management, etc.

> Ironically, it was the kernel that selected the ACPI timer, scoring it higher
> than the timestamp counter as a clock source. Perhaps code should be added to 
> ensure that the timer is not chosen if it rolls over in less than a second, 
> since this clearly leads to imprecision and missed rollovers.

The kernel attempts to notice problems when it probes for the various clocks during boot (ie, dev/acpica/acpi_hpet.c, dev/acpica/acpi_timer.c, etc); for ACPI, see acpi_timer_probe() & acpi_timer_test().

Regards,
-- 
-Chuck




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?80A6E751-9A62-4E58-A0DD-707B39C006DB>