From owner-freebsd-current@FreeBSD.ORG Sat Jul 12 13:32:26 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6299237B401 for ; Sat, 12 Jul 2003 13:32:26 -0700 (PDT) Received: from rootlabs.com (root.org [67.118.192.226]) by mx1.FreeBSD.org (Postfix) with SMTP id E542443FB1 for ; Sat, 12 Jul 2003 13:32:25 -0700 (PDT) (envelope-from nate@rootlabs.com) Received: (qmail 12989 invoked by uid 1000); 12 Jul 2003 20:32:26 -0000 Date: Sat, 12 Jul 2003 13:32:26 -0700 (PDT) From: Nate Lawson To: Hajimu UMEMOTO In-Reply-To: Message-ID: <20030712131802.I12951@root.org> References: <20030711201532.P9216@root.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: acpi-jp@jp.FreeBSD.org cc: current@freebsd.org Subject: Re: embedded controller timeout problem (was: Problems with 0619 and battery support) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Jul 2003 20:32:26 -0000 On Sun, 13 Jul 2003, Hajimu UMEMOTO wrote: > I met similar problem and I cannot get battery status at all on > today's -CURRENT. > > ACPI-0432: *** Error: Handler for [EmbeddedControl] returned AE_NO_HARDWARE_RESPONSE > ACPI-1287: *** Error: Method execution failed [\\_SB_.PCI0.ISA_.EC0_.RBAT] (Node 0xc3138f20), AE_AML_NO_RETURN_VALUE > ACPI-1287: *** Error: Method execution failed [\\_SB_.PCI0.ISA_.EC0_.RVSN] (Node 0xc3138ea0), AE_AML_NO_RETURN_VALUE > ACPI-1287: *** Error: Method execution failed [\\_SB_.PCI0.ISA_.EC0_.BAT0._BST] (Node 0xc3138dc0), AE_AML_NO_RETURN_VALUE This problem is with the current version of the embedded controller and is separate from a new acpi import. Thus I have changed the subject of this email. The problem is your EC is not replying within the given amount of time. Please apply this patch and report back to me the output. Also, can you set "hw.acpi.verbose=1" in /boot/loader.conf and report your entire dmesg output? --- acpi_ec.c 10 Jul 2003 17:22:46 -0000 1.31 +++ acpi_ec.c 12 Jul 2003 20:25:55 -0000 @@ -677,6 +677,16 @@ msleep(&sc->ec_polldelay, &sc->ec_mtx, PZERO, "ecpoll", 1/*ms*/); } + { + int waited; + + if (i < 1000) + waited = i * sc->ec_polldelay; + else + waited = 1000 + ((i - 1000) * 1000); + printf("EC waited %d us\n", waited); + } + /* Scale poll delay by the amount of time actually waited. */ if (Status == AE_OK) { period = i * sc->ec_polldelay; > [Regarding acpi-0619 diff] > Unfortunately, the patch couldn't be compiled. > > cc -O -pipe -march=pentium3 -I/usr/src/sys/modules/acpi/../../contrib/dev/acpica -D_KERNEL -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -fformat-extensions -std=c99 -DKLD_MODULE -nostdinc -I- -I/usr/src/sys/modules/acpi/../../contrib/dev/acpica -I. -I@ -I@/dev -I@/../include -fno-common -g -mno-align-long-strings -mpreferred-stack-boundary=2 -ffreestanding -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -fformat-extensions -std=c99 -c /usr/src/sys/dev/acpica/acpi.c > /usr/src/sys/dev/acpica/acpi.c: In function `acpi_identify': > bus_if.h:79: warning: inlining failed in call to `BUS_ADD_CHILD' > /usr/src/sys/dev/acpica/acpi.c:264: warning: called from here > /usr/src/sys/dev/acpica/acpi.c: In function `acpi_isa_get_logicalid': > /usr/src/sys/dev/acpica/acpi.c:716: warning: passing arg 2 of `AcpiGetObjectInfo' from incompatible pointer type > /usr/src/sys/dev/acpica/acpi.c:722: error: request for member `Value' in something not a structure or union > /usr/src/sys/dev/acpica/acpi.c:722: error: request for member `Value' in something not a structure or union > /usr/src/sys/dev/acpica/acpi.c:722: error: request for member `Value' in something not a structure or union > /usr/src/sys/dev/acpica/acpi.c:722: error: request for member `Value' in something not a structure or union > /usr/src/sys/dev/acpica/acpi.c:722: error: request for member `Value' in something not a structure or union > /usr/src/sys/dev/acpica/acpi.c:722: error: request for member `Value' in something not a structure or union > /usr/src/sys/dev/acpica/acpi.c:722: error: request for member `Value' in something not a structure or union > . . . You didn't apply part of the patch. The patch has files for /sys/dev/acpica and /sys/contrib/dev/acpica. It is self-contained. With a clean /usr/src/sys: cd /usr/src; patch < acpi-0619.diff If it doesn't modify sys/dev/acpica/acpi.c, you don't have the full patch. Please re-download it then. -Nate