From owner-freebsd-current@FreeBSD.ORG Mon Dec 22 16:05:00 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2148B16A4CE for ; Mon, 22 Dec 2003 16:05:00 -0800 (PST) Received: from dastardly.newsbastards.org.72.27.172.IN-addr.ARPA.NOSPAM.dyndns.dk (does-d9b90acd.pool.mediaWays.net [217.185.10.205]) by mx1.FreeBSD.org (Postfix) with ESMTP id DE11343D2D for ; Mon, 22 Dec 2003 16:04:42 -0800 (PST) (envelope-from bounce@NOSPAM.dyndns.dk) Received: from NOSPAM.spam.NOSPAM.spam.NOSPAM.dyndns.dk (NOSPAM.spam.NOSPAM.spam.NOSPAM.dyndns.dk [2002:d9b9:acd:0:200:c0ff:fefc:19aa]) (8.11.6/8.11.6-SPAMMERS-DeLiGHt) with ESMTP id hBN04KX30417 verified NO) for ; Tue, 23 Dec 2003 01:04:28 +0100 (CET) (envelope-from bounce@NOSPAM.dyndns.dk) Received: (from beer@localhost)hBN04Jo03608; Tue, 23 Dec 2003 01:04:19 +0100 (CET) (envelope-from bounce@NOSPAM.dyndns.dk) Date: Tue, 23 Dec 2003 01:04:19 +0100 (CET) Message-Id: <200312230004.hBN04Jo03608@NOSPAM.spam.NOSPAM.spam.NOSPAM.dyndns.dk> X-Authentication-Warning: NOSPAM.spam.NOSPAM.spam.NOSPAM.dyndns.dk: beer set sender to bounce@NOSPAM.dyndns.dk using -f To: Freebsd Current From: Barry Bouwsma References: <23707.1071348202@critter.freebsd.dk> <20031214090456.Q7016@gamplex.bde.org> X-Mailman-Approved-At: Mon, 22 Dec 2003 17:23:56 -0800 Subject: CMOS checksums (was: Re: SC520 and reboot ) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Dec 2003 00:05:00 -0000 [Drop my IPv6 address for any replies or hostname-only for IPv4...] Bruce Evans wrote... > On Sat, 13 Dec 2003, Poul-Henning Kamp wrote: > > If you run adjkerntz -a it fiddles the CMOS RTC clock and possibly the > > "century" byte I think. If your BIOS uses a checksum on the RTC and > > adjkerntz doesn't know about it, your BIOS will think the contents is > > trashed. > Actually, adjkerntz -a uses the MI interface resettodr() to set the > hardware clock, CMOS or otherwise. This has the same tiny chance of This sounds like what my latest found motherboard is suffering from. It has two problems affecting shutdowns: 1) Often, the CMOS checksum is claimed to be invalid at poweron, so my BIOS settings are lost, but not always; 2) It appears to stop keeping time at poweroff, I think. When I boot back up, ntpdate steps the time by an amount comparable to the time I had it off to swap cards or whatnot. I had to replace the on-board lithium battery, otherwise I'd lose CMOS checksums every time. Ideally I'd rather never powerdown, but I'm wondering if it's possible for FreeBSD to ignore the CMOS clock -- never updating it, either with resettodr() (in sys/kern/kern_time.c that I've found; haven't done a rigorous search yet) or any other call that jerks around the CMOS time, so I can avoid, hopefully, the checksum errors that pop up now and then. Meaning my CMOS time would remain 2008 or 1986 or whatever it's set itself to randomly, or 2003/2004 but losing a few minutes each poweroff, while the system time would be set at boot (ntpdate/ntpd) and remain accurate. There would be no correlation between the two, other than that the CMOS time ticks so long as power is applied. Is this possible, or am I going to break something, more than the occasional CMOS checksum failures I get now? Seems like I'd comment out any resettodr() calls I find, and if anything else adjusts the CMOS clock, I'd have to find and comment it out too. Comments? The motherboard seems of vintage 1994-1997-ish, intended for Pentiums of roughly 75-150MHz speed. It has other minor issues too, but seems to work otherwise... thanks barry bouwsma scrap computer collector