From owner-freebsd-mobile@FreeBSD.ORG Thu Dec 18 09:39:58 2003 Return-Path: Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AE88816A4CF for ; Thu, 18 Dec 2003 09:39:58 -0800 (PST) Received: from mail3.speakeasy.net (mail3.speakeasy.net [216.254.0.203]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3E11543E53 for ; Thu, 18 Dec 2003 09:33:12 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: (qmail 17257 invoked from network); 18 Dec 2003 17:32:02 -0000 Received: from dsl027-160-063.atl1.dsl.speakeasy.net (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) encrypted SMTP for ; 18 Dec 2003 17:32:02 -0000 Received: from laptop.baldwin.cx (laptop.baldwin.cx [192.168.0.4]) by server.baldwin.cx (8.12.10/8.12.10) with ESMTP id hBIHVxM0023639; Thu, 18 Dec 2003 12:31:59 -0500 (EST) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.4 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <20031218151056.S46397@morgan.upsys.se> Date: Thu, 18 Dec 2003 12:32:11 -0500 (EST) From: John Baldwin To: Mauritz Sundell X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) cc: freebsd-mobile@freebsd.org Subject: Re: ACPI/PCI-bus issue with compaq evo n160 X-BeenThere: freebsd-mobile@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Mobile computing with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Dec 2003 17:39:59 -0000 On 18-Dec-2003 Mauritz Sundell wrote: > > On Wed, 17 Dec 2003, John Baldwin wrote: > >> >> On 17-Dec-2003 Fredrik Lindberg wrote: >> > The solution suggested by Mauritz worked, the ACPI stuff works now. >> > This is what I have in my loader.conf >> > >> > debug.acpi.disable="lid pci_link" >> > hw.pci.allow_unsupported_io_range="1" >> > hw.cbb.start_memory="536870912" >> >> What if you remove the debug.acpi.disable line? >> >> Btw, you can disable the lid suspending stuff by using >> >> sysctl hw.acpi.lid_switch_state=NONE >> >> without having to disable the lid in debug.acpi.disable. >> > It is to late to disable the lid after init have started. > If I close the lid during the kernel boot it goes to an > hanging sleep. > > The reason I may close the lid during boot is that when I > am at work I usally plug in my personal Compaq Evo to the > ethernet, starting it and closes the lid. > > But nowadays when I most of the time use the suspend to disk > feature this is not an issue. But sometimes I want to do > an reboot and close the lid. > > I have tried to set > hw.acpi.lid_switch_state="S0" > in device.hints and loader.conf but it does not work > (not with ="NONE" either) You would need to set it in /etc/sysctl.conf. Alternatively, could add code to parse the loader versions to the code in acpi.c that sets the initial values: sc->acpi_power_button_sx = ACPI_POWER_BUTTON_DEFAULT_SX; sc->acpi_sleep_button_sx = ACPI_SLEEP_BUTTON_DEFAULT_SX; sc->acpi_lid_switch_sx = ACPI_LID_SWITCH_DEFAULT_SX; sc->acpi_standby_sx = ACPI_STATE_S1; sc->acpi_suspend_sx = ACPI_STATE_S3; Also, you could patch acpivar.h locally to set ACPI_LID_SWITCH_DEFAULT_SX to ACPI_S5 + 1. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/