From owner-cvs-src@FreeBSD.ORG Mon Mar 26 18:32:13 2007 Return-Path: X-Original-To: cvs-src@freebsd.org Delivered-To: cvs-src@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8DE7716A402 for ; Mon, 26 Mar 2007 18:32:13 +0000 (UTC) (envelope-from nate@root.org) Received: from root.org (root.org [67.118.192.226]) by mx1.freebsd.org (Postfix) with ESMTP id 727B813C458 for ; Mon, 26 Mar 2007 18:32:13 +0000 (UTC) (envelope-from nate@root.org) Received: (qmail 52781 invoked from network); 26 Mar 2007 18:14:06 -0000 Received: from ppp-71-139-28-99.dsl.snfc21.pacbell.net (HELO ?10.0.0.235?) (nate-mail@71.139.28.99) by root.org with ESMTPA; 26 Mar 2007 18:14:06 -0000 Message-ID: <46080D67.6030203@root.org> Date: Mon, 26 Mar 2007 11:13:59 -0700 From: Nate Lawson User-Agent: Thunderbird 1.5.0.7 (X11/20061027) MIME-Version: 1.0 To: cvs-src@freebsd.org, cvs-all@freebsd.org, src-committers@freebsd.org References: <20070326180338.6466316A5AC@hub.freebsd.org> In-Reply-To: <20070326180338.6466316A5AC@hub.freebsd.org> X-Enigmail-Version: 0.94.1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Subject: Re: cvs commit: src/sys/sys cpu.h eventhandler.h src/sys/kern kern_cpu.c src/sys/i386/i386 identcpu.c tsc.c src/sys/i386/isa prof_machdep.c src/sys/amd64/amd64 identcpu.c prof_machdep.c tsc.c src/sys/contrib/altq/altq altq_subr.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Mar 2007 18:32:13 -0000 Nate Lawson wrote: > njl 2007-03-26 18:03:30 UTC > > FreeBSD src repository > > Modified files: > sys/sys eventhandler.h cpu.h > sys/kern kern_cpu.c > sys/i386/i386 tsc.c identcpu.c > sys/i386/isa prof_machdep.c > sys/amd64/amd64 tsc.c identcpu.c prof_machdep.c > sys/contrib/altq/altq altq_subr.c > Log: > Add an interface for drivers to be notified of changes to CPU frequency. > cpufreq_pre_change is called before the change, giving each driver a chance > to revoke the change. cpufreq_post_change provides the results of the > change (success or failure). cpufreq_levels_changed gives the unit number > of the cpufreq device whose number of available levels has changed. Hook > in all the drivers I could find that needed it. > > * TSC: update TSC frequency value. When the available levels change, take the > highest possible level and notify the timecounter set_cputicker() of that > freq. This gets rid of the "calcru: runtime went backwards" messages. > * identcpu: updates the sysctl hw.clockrate value > * Profiling: if profiling is active when the clock changes, let the user > know the results may be inaccurate. > > Reviewed by: bde, phk > MFC after: 1 month > > Revision Changes Path > 1.153 +17 -0 src/sys/amd64/amd64/identcpu.c > 1.29 +38 -2 src/sys/amd64/amd64/prof_machdep.c > 1.207 +94 -3 src/sys/amd64/amd64/tsc.c > 1.9 +19 -0 src/sys/contrib/altq/altq/altq_subr.c > 1.175 +17 -0 src/sys/i386/i386/identcpu.c > 1.207 +94 -3 src/sys/i386/i386/tsc.c > 1.30 +43 -13 src/sys/i386/isa/prof_machdep.c > 1.24 +40 -26 src/sys/kern/kern_cpu.c > 1.4 +33 -1 src/sys/sys/cpu.h > 1.36 +11 -0 src/sys/sys/eventhandler.h Forgot to add that altq was also updated to use the new TSC frequency after it changes. I wasn't able to test the altq change, but compiled it and it is relatively small. I tested all the other changes on my laptop. -- Nate