Re: [gpm] Untangling the sleep hotkey mess



On Monday 09 January 2006 10:30, Matthew Garrett wrote:
> On Mon, Jan 09, 2006 at 10:19:00AM +0800, Yu Luming wrote:
>  > Re: dev_acpi:
>  > The key point is AML code shouldn't be exposed in userspace. It is too
>  > ugly.
>
>  It may be ugly, but it /works/. We can't predict what vendors will do in
>  terms of providing hotkey support in future, and exposing a limited
>  interface to userspace would probably just result in it having to be
>  extended later on, which again forces us into kernel patching.
They should come up with some kinds of specs for hotkey in the future.
Otherwise, the problem won't go away.

>
>  With my Ubuntu hat on:
>
>  dev_acpi would make life a lot easier for us than the current solutions.
>  A single userspace application has the advantage that it can be
>  maintained in a nice cross-distribution way, and we can rapidly fold in
>  extra support based on testing reports.
Comparing with generic hotkey solution, dev_acpi solution cannot prevent any 
trouble in terms of supportability, and manageability.

For dev_acpi,  you won't need kernel patch. But you need to know everything in 
AML world from user space.

For hotkey.c, there is an auto-load-call-back function that will automatically 
detect and install configure data based on well-known acpi device object's 
PNP ID, and well-known hotkey AML method names.
And the manual configure interface is intended to be used as debug tool.

So, if you use hotkey.c you don't need to know anything in AML world from user 
space, if you are lucky. I expect in the future, the well-know acpi device 
PNP ID, and well-know AML methods names would become part of ACPI spec.

PS.  According to my testing, windows do have platform specific hotkey 
drivers.

>
>  --
>  Matthew Garrett | mjg59 srcf ucam org

-- 
Thanks,
Luming



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]