From owner-freebsd-stable@FreeBSD.ORG Fri May 11 18:32:35 2007 Return-Path: X-Original-To: freebsd-stable@freebsd.org Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 72D6B16A400 for ; Fri, 11 May 2007 18:32:35 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from gaia.nimnet.asn.au (nimbin.lnk.telstra.net [139.130.45.143]) by mx1.freebsd.org (Postfix) with ESMTP id CC6AF13C458 for ; Fri, 11 May 2007 18:32:33 +0000 (UTC) (envelope-from smithi@nimnet.asn.au) Received: from localhost (smithi@localhost) by gaia.nimnet.asn.au (8.8.8/8.8.8R1.5) with SMTP id EAA01226; Sat, 12 May 2007 04:32:12 +1000 (EST) (envelope-from smithi@nimnet.asn.au) Date: Sat, 12 May 2007 04:32:11 +1000 (EST) From: Ian Smith To: Tom Evans In-Reply-To: <1178900585.1231.63.camel@zoot.mintel.co.uk> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: freebsd-stable@freebsd.org, martin.dieringer@gmx.de Subject: Re: clock problem X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 May 2007 18:32:35 -0000 On Fri, 11 May 2007, Tom Evans wrote: > On Fri, 2007-05-11 at 08:53 -0600, M. Warner Losh wrote: > > In message: <20070511110759.L700@thinkpad.dieringer.dyndns.org> > > Martin Dieringer writes: > > : This is NOT a hardware problem. 1. I have this on 2 machines, 2. the > > : problem is solved by switching to ACPI instead of APM > > > > It is a hardware problem. APM + powerd changes the frequency of the > > TSC. If the TSC is used as the time source, then you'll get bad > > timekeeping. ACPI uses its own frequency source that is much more > > stable and independent of the TSC, so switching to it fixes the > > problem because you are switching the hardware from using a really bad > > frequency source with ugly steps to using a good frequency source w/o > > steps. > > > > Warner Yes, but Martin already showed it was using the i8254, not TSC; would you expect the same effect using powerd with the i8254 clock? It seems so, unless it's some problem with est and/or p4tcc under APM (canoworms) Runnning APM, at least on my ol' Compaq 1500c 5.5-S running APM - really too ancient to expect ACPI to work properly - on verbose boot states: Calibrating clock(s) ... i8254 clock: 1193216 Hz CLK_USE_I8254_CALIBRATION not specified - using default frequency Timecounter "i8254" frequency 1193182 Hz quality 0 Calibrating TSC clock ... TSC clock: 300011839 Hz [..] TSC timecounter disabled: APM enabled. <<<<<<<<<<<< Timecounter "TSC" frequency 300011839 Hz quality -1000 ie: kern.timecounter.hardware: i8254 kern.timecounter.choice: TSC(-1000) i8254(0) dummy(-1000000) > Surely that would imply that it is a software misconfiguration issue. If > the TSC is unreliable under fairly standard duties, and there exists an > alternate source that is reliable, surely that indicates the > manufacturer has identified a problem, and solved it with alternate > hardware. > > The failure then to use the correct hardware is a software > misconfiguration. If one considers disabling ACPI and enabling APM misconfiguration .. which in Martin's case it turned out to be, since his ACPI works, but est0: on cpu0 p4tcc0: on cpu0 apm0: on motherboard apm0: found APM BIOS v1.2, connected at v1.2 together with powerd appeared to heavily retard time on both laptops, beyond ntpd's ability to cope. Cheers, Ian