From owner-svn-src-head@FreeBSD.ORG Mon Nov 8 21:50:46 2010 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3EA2C106566B; Mon, 8 Nov 2010 21:50:46 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2C3968FC19; Mon, 8 Nov 2010 21:50:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id oA8Lok2J055877; Mon, 8 Nov 2010 21:50:46 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id oA8LokTg055871; Mon, 8 Nov 2010 21:50:46 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201011082150.oA8LokTg055871@svn.freebsd.org> From: John Baldwin Date: Mon, 8 Nov 2010 21:50:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r215016 - in head/sys/boot: common forth i386/libi386 i386/loader X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Nov 2010 21:50:46 -0000 Author: jhb Date: Mon Nov 8 21:50:45 2010 New Revision: 215016 URL: http://svn.freebsd.org/changeset/base/215016 Log: Remove support for autoloading ACPI from the loader. Leave in the code to detect ACPI and export info such as the location of the RSDP via hints as that is still useful. Modified: head/sys/boot/common/loader.8 head/sys/boot/forth/beastie.4th head/sys/boot/i386/libi386/biosacpi.c head/sys/boot/i386/libi386/i386_module.c head/sys/boot/i386/loader/help.i386 Modified: head/sys/boot/common/loader.8 ============================================================================== --- head/sys/boot/common/loader.8 Mon Nov 8 21:23:28 2010 (r215015) +++ head/sys/boot/common/loader.8 Mon Nov 8 21:50:45 2010 (r215016) @@ -334,12 +334,6 @@ Some options may require a value, while others define behavior just by being set. Both types of builtin variables are described below. .Bl -tag -width bootfile -.It Va acpi_load -Unset this to disable automatic loading of the ACPI module. -See also -.Va hint.acpi.0.disabled -in -.Xr device.hints 5 . .It Va autoboot_delay Number of seconds .Ic autoboot Modified: head/sys/boot/forth/beastie.4th ============================================================================== --- head/sys/boot/forth/beastie.4th Mon Nov 8 21:23:28 2010 (r215015) +++ head/sys/boot/forth/beastie.4th Mon Nov 8 21:50:45 2010 (r215016) @@ -141,13 +141,11 @@ at-xy ." `--{__________) " ; : acpienabled? ( -- flag ) - s" acpi_load" getenv + s" hint.acpi.0.rsdp" getenv dup -1 = if drop false exit then - s" YES" compare-insensitive 0<> if - false exit - then + 2drop s" hint.acpi.0.disabled" getenv dup -1 <> if s" 0" compare 0<> if @@ -254,11 +252,9 @@ set-current dup bootkey @ = if 0 boot then dup bootacpikey @ = if acpienabled? if - s" acpi_load" unsetenv s" 1" s" hint.acpi.0.disabled" setenv s" 1" s" loader.acpi_disabled_by_user" setenv else - s" YES" s" acpi_load" setenv s" 0" s" hint.acpi.0.disabled" setenv then 0 boot @@ -266,7 +262,6 @@ set-current dup bootsafekey @ = if s" arch-i386" environment? if drop - s" acpi_load" unsetenv s" 1" s" hint.acpi.0.disabled" setenv s" 1" s" loader.acpi_disabled_by_user" setenv s" 1" s" hint.apic.0.disabled" setenv Modified: head/sys/boot/i386/libi386/biosacpi.c ============================================================================== --- head/sys/boot/i386/libi386/biosacpi.c Mon Nov 8 21:23:28 2010 (r215015) +++ head/sys/boot/i386/libi386/biosacpi.c Mon Nov 8 21:50:45 2010 (r215016) @@ -40,7 +40,7 @@ __FBSDID("$FreeBSD$"); #include "actbl.h" /* - * Detect ACPI and export information about the APCI BIOS into the + * Detect ACPI and export information about the ACPI BIOS into the * environment. */ @@ -56,8 +56,6 @@ biosacpi_detect(void) char buf[24]; int revision; - /* XXX check the BIOS datestamp */ - /* locate and validate the RSDP */ if ((rsdp = biosacpi_find_rsdp()) == NULL) return; @@ -82,9 +80,6 @@ biosacpi_detect(void) sprintf(buf, "%d", rsdp->Length); setenv("hint.acpi.0.xsdt_length", buf, 1); } - /* XXX other tables? */ - - setenv("acpi_load", "YES", 1); } /* Modified: head/sys/boot/i386/libi386/i386_module.c ============================================================================== --- head/sys/boot/i386/libi386/i386_module.c Mon Nov 8 21:23:28 2010 (r215015) +++ head/sys/boot/i386/libi386/i386_module.c Mon Nov 8 21:50:45 2010 (r215016) @@ -44,25 +44,7 @@ __FBSDID("$FreeBSD$"); int i386_autoload(void) { - int error; - int disabled; - char *rv; /* XXX use PnP to locate stuff here */ - - /* autoload ACPI support */ - /* XXX should be in 4th keyed off acpi_load */ - disabled = 0; - rv = getenv("hint.acpi.0.disabled"); - if (rv != NULL && strncmp(rv, "0", 1) != 0) { - disabled = 1; - } - - if (getenv("acpi_load") && (!disabled)) { - error = mod_load("acpi", NULL, 0, NULL); - if (error != 0) - printf("ACPI autoload failed - %s\n", strerror(error)); - } - return(0); } Modified: head/sys/boot/i386/loader/help.i386 ============================================================================== --- head/sys/boot/i386/loader/help.i386 Mon Nov 8 21:23:28 2010 (r215015) +++ head/sys/boot/i386/loader/help.i386 Mon Nov 8 21:50:45 2010 (r215016) @@ -1,22 +1,4 @@ ################################################################################ -# TACPI DControl ACPI module behaviour - - $acpi_load - - If set, the ACPI module will be loaded. Clear it with - - unset acpi_load - - $hint.acpi.0.disabled="1" - - If set, the ACPI module won't be loaded. - - Note that the ACPI autodetection sets a number of hints to - pass information to the ACPI module. These should not be - overridden, or system behaviour will be undefined. - - -################################################################################ # Treboot DReboot the system reboot