From owner-freebsd-acpi@FreeBSD.ORG Sat Feb 13 11:21:06 2010 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 453B8106566B; Sat, 13 Feb 2010 11:21:06 +0000 (UTC) (envelope-from d.walter@0x90.at) Received: from mail.0x90.at (s2.linuxsolutions.at [83.218.160.157]) by mx1.freebsd.org (Postfix) with ESMTP id 95E358FC0C; Sat, 13 Feb 2010 11:21:02 +0000 (UTC) Received: from localhost (unknown [127.0.0.1]) by mail.0x90.at (Postfix) with ESMTP id 6379678C2A; Sat, 13 Feb 2010 12:42:59 +0100 (CET) X-Virus-Scanned: amavisd-new at 0x90.at Received: from mail.0x90.at ([127.0.0.1]) by localhost (mails.0x90.at [127.0.0.1]) (amavisd-new, port 10024) with LMTP id a3kWBLw5dm7A; Sat, 13 Feb 2010 12:42:34 +0100 (CET) Received: from [192.168.1.2] (chello213047242248.tirol.surfer.at [213.47.242.248]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.0x90.at (Postfix) with ESMTPSA id 7D3CB78C11; Sat, 13 Feb 2010 12:42:33 +0100 (CET) Date: Sat, 13 Feb 2010 12:20:34 +0100 (CET) From: Daniel Walter X-X-Sender: sahne@mini-beast To: Jung-uk Kim In-Reply-To: <201002122125.56882.jkim@FreeBSD.org> Message-ID: References: <201002121541.29429.jkim@FreeBSD.org> <201002122125.56882.jkim@FreeBSD.org> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="-496892480-2074569814-1266060041=:1389" Cc: freebsd-acpi@FreeBSD.org Subject: Re: Call for testers acpi_dell 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: Sat, 13 Feb 2010 11:21:06 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. ---496892480-2074569814-1266060041=:1389 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed On Fri, 12 Feb 2010, Jung-uk Kim wrote: > On Friday 12 February 2010 04:38 pm, Daniel Walter wrote: >> On Fri, 12 Feb 2010, Jung-uk Kim wrote: >>> On Friday 12 February 2010 03:12 pm, Daniel Walter wrote: >>>> On Fri, 12 Feb 2010, Jung-uk Kim wrote: >>>>> On Friday 12 February 2010 02:37 pm, Daniel Walter wrote: >>>>>> On Fri, 12 Feb 2010, Jung-uk Kim wrote: >>>>>>> On Friday 12 February 2010 01:33 pm, Daniel Walter wrote: >>>>>>>> On Fri, 12 Feb 2010, Jung-uk Kim wrote: >>>>>>>>> On Friday 12 February 2010 12:48 pm, Daniel Walter wrote: >>>>>>>>>> Hi all, >>>>>>>>>> >>>>>>>>>> I've written a small kernel driver to support Dell Mini >>>>>>>>>> 1011 (aka Dell Mini 10v) Brightness Controll Buttons. >>>>>>>>>> Since I do not have any other Dell Notebooks, I'd like you >>>>>>>>>> to test this module on other Dell Notebooks as well. >>>>>>>>>> >>>>>>>>>> This driver is in an early stage, but future releases will >>>>>>>>>> also support the rfkill switch and CRT switch. >>>>>>>>>> >>>>>>>>>> Currently following features are implemented: >>>>>>>>>> * Increase / Decrease Brightness >>>>>>>>>> * Change brightness if AC is connected / disconnected >>>>>>>>>> >>>>>>>>>> TODO: >>>>>>>>>> * Add CRT Support >>>>>>>>>> * Add Sysctl to define brightness levels for eco and ac >>>>>>>>>> powerprofile * Add Support for RF-Kill Switch >>>>>>>>>> >>>>>>>>>> Any suggestions are welcome >>>>>>>>> >>>>>>>>> I just quickly glanced at it but I failed see anything >>>>>>>>> quite specific to Dell laptops except for "TODO: Add >>>>>>>>> support for RF-Kill Switch". acpi_video(4) should be able >>>>>>>>> to do what you want. Am I missing something here? >>>>>>>>> >>>>>>>>> Jung-uk Kim >>>>>>>> >>>>>>>> hi, >>>>>>>> >>>>>>>> Yes it is possible to control the brightness using >>>>>>>> acpi_video(4) via sysctl but there is no support for the >>>>>>>> FN-Buttons. This module adds the support for those buttons. >>>>>>> >>>>>>> I see. However, my point is the probe function does not seem >>>>>>> specific to Dell laptops. In fact, you are just checking >>>>>>> _BCL transition, i.e., effectively it just makes a generic >>>>>>> acpi_video notify handler for brightness change. >>>>>>> >>>>>>> Jung-uk Kim >>>>>> >>>>>> Oh, I've completly overlooked this one. Sorry for that, I >>>>>> should replace the probing with a Dell specific probing >>>>>> instead. Do you have any suggestions to this one ? >>>>> >>>>> It totally depends on DSDT of your laptop model and you will >>>>> have to maintain the list of these ACPI handles, unfortunately. >>>>> Please see acpi_asus.c for example. >>>>> >>>>> If you are interested in generic acpi_video(4) enhancement, you >>>>> just need to extend acpi_video.c to get these notifications, >>>>> i.e., 0x86 and 0x87. FYI, acpi_video can only handle 0x80 and >>>>> 0x81 events ATM. Please read ACPI specification Appendix B. >>>>> Video Extensions, especially B.6 and B.7 are what you are >>>>> looking for. >>>>> >>>>> Jung-uk Kim >>>> >>>> Hi I'll take a look at my DSDT again ... >>>> >>>> I've also will take a look at Appendix B of the current ACPI >>>> spec to see if 0x86 and 0x87 are OEM or part of the standard. If >>>> they are not completly out of spec I'll patch acpi_video(4) and >>>> send it again to the list. >>> >>> 0x86/0x87 is part of the spec. and it should be handled by >>> acpi_video IMHO. >>> >>> Jung-uk Kim >> >> hi, >> >> as you suggested I've written a patch for acpi_video(4) to support >> the 0x86 and 0x87 notifications. the support for 0x85, 0x88, 0x89 >> (also specified in ACPI Standard Appendix B7) is not yet >> implemented. >> >> Could anyone with a ACPI sending 0x86 and 0x87 test the patch ? >> >> thanks for the help and pointing my in the right direction. > > I just went ahead and committed a rewritten version. :-) > > Thanks! > > Jung-uk Kim Hi, I've quickly added support for 0x85 (Cycle Brightness) and 0x88 (Zero Brightness). Could you have a look at the patch? Would you mind MFC the acpi_video(4) ? regards and thanks Daniel Walter ---496892480-2074569814-1266060041=:1389 Content-Type: TEXT/PLAIN; charset=US-ASCII; name=acpi_video.diff Content-Transfer-Encoding: BASE64 Content-ID: Content-Description: Content-Disposition: attachment; filename=acpi_video.diff LS0tIGFjcGlfdmlkZW8uYwkyMDEwLTAyLTEzIDA2OjM4OjIxLjAwMDAwMDAw MCArMDEwMA0KKysrIGFjcGlfdmlkZW8uYwkyMDEwLTAyLTEzIDEyOjE0OjAz LjAwMDAwMDAwMCArMDEwMA0KQEAgLTEwMyw4ICsxMDMsMTAgQEANCiAvKiBl dmVudHMgKi8NCiAjZGVmaW5lIFZJRF9OT1RJRllfU1dJVENIRUQJMHg4MA0K ICNkZWZpbmUgVklEX05PVElGWV9SRVBST0JFCTB4ODENCisjZGVmaW5lCVZJ RF9OT1RJRllfQ1lDX0JSTgkweDg1DQogI2RlZmluZQlWSURfTk9USUZZX0lO Q19CUk4JMHg4Ng0KICNkZWZpbmUJVklEX05PVElGWV9ERUNfQlJOCTB4ODcN CisjZGVmaW5lCVZJRF9OT1RJRllfWlJPX0JSTgkweDg4DQogDQogLyogX0RP UyAoRW5hYmxlL0Rpc2FibGUgT3V0cHV0IFN3aXRjaGluZykgYXJndW1lbnQg Yml0cyAqLw0KICNkZWZpbmUgRE9TX1NXSVRDSF9NQVNLCQkzDQpAQCAtNjUx LDYgKzY1Myw3IEBADQogCX0NCiANCiAJc3dpdGNoIChub3RpZnkpIHsNCisJ Y2FzZSBWSURfTk9USUZZX0NZQ19CUk46DQogCWNhc2UgVklEX05PVElGWV9J TkNfQlJOOg0KIAljYXNlIFZJRF9OT1RJRllfREVDX0JSTjoNCiAJCWlmICh2 by0+dm9fbGV2ZWxzID09IE5VTEwpDQpAQCAtNjcxLDExICs2NzQsMTkgQEAN CiAJCQkJCW5ld19sZXZlbCA9IGo7DQogCQkJfQ0KIAkJfQ0KKwkJaWYgKG5v dGlmeSA9PSBWSURfTk9USUZZX0NZQ19CUk4gJiYgbmV3X2xldmVsID09IGxl dmVsKQ0KKwkJCW5ld19sZXZlbD0gdm8tPnZvX2xldmVsc1syXTsNCiAJCWlm IChuZXdfbGV2ZWwgIT0gbGV2ZWwpIHsNCiAJCQl2b19zZXRfYnJpZ2h0bmVz cyhoYW5kbGUsIG5ld19sZXZlbCk7DQogCQkJdm8tPnZvX2JyaWdodG5lc3Mg PSBuZXdfbGV2ZWw7DQogCQl9DQogCQlicmVhazsNCisJY2FzZSBWSURfTk9U SUZZX1pST19CUk46DQorCQlpZiAoYWNwaV92aWRlb192b19jaGVja19sZXZl bCh2bywgMCkgPT0gMCkgew0KKwkJCXZvX3NldF9icmlnaHRuZXNzKGhhbmRs ZSwgMCk7DQorCQkJdm8tPnZvX2JyaWdodG5lc3MgPSAwOw0KKwkJfQ0KKwkJ YnJlYWs7DQogCWRlZmF1bHQ6DQogCQlwcmludGYoInVua25vd24gbm90aWZ5 IGV2ZW50IDB4JXggZnJvbSAlc1xuIiwNCiAJCSAgICBub3RpZnksIGFjcGlf bmFtZShoYW5kbGUpKTsNCg== ---496892480-2074569814-1266060041=:1389--