From owner-freebsd-acpi@FreeBSD.ORG Tue Jan 29 19:17:30 2008 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 90FB216A46B for ; Tue, 29 Jan 2008 19:17:30 +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 5A61613C45B for ; Tue, 29 Jan 2008 19:17:30 +0000 (UTC) (envelope-from nate@root.org) Received: (qmail 40117 invoked from network); 29 Jan 2008 19:17:30 -0000 Received: from adsl-71-141-123-117.dsl.snfc21.pacbell.net (HELO ?192.168.1.77?) (nate-mail@71.141.123.117) by root.org with ESMTPA; 29 Jan 2008 19:17:30 -0000 Message-ID: <479F7BC4.9000004@root.org> Date: Tue, 29 Jan 2008 11:17:24 -0800 From: Nate Lawson User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) MIME-Version: 1.0 To: =?ISO-8859-2?Q?Artur_Ba=E6?= References: <200801291205.m0TC5gQP052493@sana.init-main.com> <200801291940.05952.artur@ebasoft.com.pl> In-Reply-To: <200801291940.05952.artur@ebasoft.com.pl> X-Enigmail-Version: 0.95.6 Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 8bit Cc: freebsd-acpi@freebsd.org Subject: Re: Need info about ACPI - implementing acer_acpi, amilo 1650g X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Jan 2008 19:17:30 -0000 Artur Bać wrote: > Tuesday 29 of January 2008 13:05:42 Takanori Watanabe napisał(a): >> I have another laptop PC with ACPI WMI device, and try to implement >> some namespace detection. But leave untouched so long because >> I could not find how to make them do useful thing. >> >> http://www.init-main.com/a2000/acpi_wmi.c > > One thing that is suspicious in Your code > > if(AcpiEvaluateObject(devh, "_WDG", NULL, &wdg_buf)){ > device_printf(dev, "Cannot Fetch _WDG"); > return ENXIO; > } > > > Evaluate is aimed at calling methods As I understand interface, I didn't find > any other info for now. > > in my DSDT _WDG is a buffer not method... "Evaluate" means to run the method and return the value OR return the contents of the object if it is not a function. In your case, Evaluate will return an ACPI_BUFFER object. You can see code for dealing with that in many drivers, for instance sys/dev/acpica/acpi_perf.c -- Nate