From owner-cvs-all@FreeBSD.ORG Sun Jan 7 21:53:43 2007 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 98E1916A492; Sun, 7 Jan 2007 21:53:43 +0000 (UTC) (envelope-from njl@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [69.147.83.41]) by mx1.freebsd.org (Postfix) with ESMTP id 7E5CD13C4B1; Sun, 7 Jan 2007 21:53:43 +0000 (UTC) (envelope-from njl@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id l07Lrhtv047824; Sun, 7 Jan 2007 21:53:43 GMT (envelope-from njl@repoman.freebsd.org) Received: (from njl@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id l07LrgTZ047823; Sun, 7 Jan 2007 21:53:42 GMT (envelope-from njl) Message-Id: <200701072153.l07LrgTZ047823@repoman.freebsd.org> From: Nate Lawson Date: Sun, 7 Jan 2007 21:53:42 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/etc/rc.d power_profile src/sys/dev/acpica acpi.c acpi_cpu.c acpi_package.c acpi_perf.c acpi_throttle.c acpivar.h X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Jan 2007 21:53:43 -0000 njl 2007-01-07 21:53:42 UTC FreeBSD src repository Modified files: etc/rc.d power_profile sys/dev/acpica acpi.c acpi_cpu.c acpi_package.c acpi_perf.c acpi_throttle.c acpivar.h Log: Re-work Cx handling to be per-cpu and asymmetrical, fixing support on modern dual-core systems as well. - Parse the _CST packages for each cpu and track all the states individually, on a per-cpu basis. - Revert to generic FADT/P_BLK based Cx control if the _CST package is not present on all cpus. In that case, the new driver will still support per-cpu Cx state handling. The driver will determine the highest Cx level that can be supported by all the cpus and configure the available Cx state based on that. - Fixed the case where multiple cpus in the system share the same registers for Cx state handling. To do that, added a new flag parameter to the acpi_PkgGas and acpi_bus_alloc_gas functions that enable the caller to add the RF_SHAREABLE flag. This flag could also be useful to other callers (acpi_throttle?) in the tree but this change is not yet made. - For Core Duo cpus, both cores seems to be taken out of C3 state when any one of the cores need to transition out. This broke the short sleep detection logic. It is disabled now if there is more than one cpu in the system for now as it fixed it in my case. This quirk may need to be re-enabled later differently. - Added support to control cx_lowest on a per-cpu basis. There is still a generic cx_lowest to enable changing cx_lowest for all cpus with a single sysctl and for ease of use. Sample output for the new sysctl: dev.cpu.0.cx_supported: C1/1 C2/1 C3/57 dev.cpu.0.cx_lowest: C3 dev.cpu.0.cx_usage: 0.00% 43.16% 56.83% dev.cpu.1.cx_supported: C1/1 C2/1 C3/57 dev.cpu.1.cx_lowest: C3 dev.cpu.1.cx_usage: 0.00% 45.65% 54.34% hw.acpi.cpu.cx_lowest: C3 This work was done by Stephane E. Potvin with some simple reworking by myself. Thank you. Submitted by: Stephane E. Potvin MFC after: 2 weeks Revision Changes Path 1.10 +1 -1 src/etc/rc.d/power_profile 1.230 +2 -2 src/sys/dev/acpica/acpi.c 1.60 +310 -196 src/sys/dev/acpica/acpi_cpu.c 1.9 +2 -2 src/sys/dev/acpica/acpi_package.c 1.25 +3 -3 src/sys/dev/acpica/acpi_perf.c 1.10 +2 -2 src/sys/dev/acpica/acpi_throttle.c 1.103 +3 -2 src/sys/dev/acpica/acpivar.h