From owner-freebsd-stable@FreeBSD.ORG Wed Mar 1 00:58:02 2006 Return-Path: X-Original-To: freebsd-stable@FreeBSD.org Delivered-To: freebsd-stable@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 545A616A420; Wed, 1 Mar 2006 00:58:02 +0000 (GMT) (envelope-from nate@root.org) Received: from ylpvm43.prodigy.net (ylpvm43-ext.prodigy.net [207.115.57.74]) by mx1.FreeBSD.org (Postfix) with ESMTP id CDCBD43D46; Wed, 1 Mar 2006 00:58:01 +0000 (GMT) (envelope-from nate@root.org) Received: from pimout7-ext.prodigy.net (pimout7-int.prodigy.net [207.115.4.147]) by ylpvm43.prodigy.net (8.12.10 outbound/8.12.10) with ESMTP id k210w4RP012006; Tue, 28 Feb 2006 19:58:04 -0500 X-ORBL: [71.139.114.10] Received: from [10.0.5.50] (ppp-71-139-114-10.dsl.snfc21.pacbell.net [71.139.114.10]) by pimout7-ext.prodigy.net (8.13.4 outbound domainkey aix/8.13.4) with ESMTP id k210vxpu171804; Tue, 28 Feb 2006 19:57:59 -0500 Message-ID: <4404F18B.7090006@root.org> Date: Tue, 28 Feb 2006 16:57:47 -0800 From: Nate Lawson User-Agent: Thunderbird 1.5 (Windows/20051201) MIME-Version: 1.0 To: Marcus Alves Grando References: <4404E852.80908@FreeBSD.org> <4404EC20.8030500@root.org> <4404EF3F.8050006@FreeBSD.org> In-Reply-To: <4404EF3F.8050006@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: FreeBSD Stable Subject: Re: sysctl: dev.cpu.0.freq: Device busy (cpufreq p4tcc / RELENG_6) 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: Wed, 01 Mar 2006 00:58:02 -0000 I'll approve a commit if you send me a patch. Add something like this to the SYSCTL VARIABLES section: The frequency cannot be changed if TSC is in use as the timecounter. This is because the timecounter system needs to use a source that has a constant rate. The timecounter source can be changed with the kern.timecounter.hardware sysctl. Marcus Alves Grando wrote: > Well, works. Thanks. It's possible to printf some message about this if > kern.timecounter.hardware != ACPI-fast? Or add message in cpufreq(4)? > > Thanks > > Nate Lawson wrote: >> Marcus Alves Grando wrote: >>> I have problems in cpufreq in RELENG_6 (today). >>> >>> I try to set another frequency in my laptop and get this error: >>> >>> # sysctl dev.cpu.0.freq=250 >>> dev.cpu.0.freq: 2000 >>> sysctl: dev.cpu.0.freq: Device busy >>> >>> Timecounter "TSC" frequency 1995011972 Hz quality 800 >>> Timecounters tick every 1.000 msec >> >> Try setting your timecounter to acpi or i8254 (not TSC): >> >> sysctl kern.timecounter.hardware="acpi" >> >> Without complicated recalibration code (which no one has written yet), >> we can't base our system time off the TSC counter when cpufreq is >> changing it. >> > -- Nate