Calling all hotkey expertise...

Andy Whitcroft apw at canonical.com
Fri Feb 18 09:04:38 UTC 2011


On Thu, Feb 17, 2011 at 10:15:06PM -0200, Herton Ronaldo Krzesinski wrote:
> Em Qui, 2011-02-17 às 12:31 +0000, Colin Ian King escreveu:
> > Thanks Herton,
> > 
> > On Thu, 2011-02-10 at 19:58 -0200, Herton Ronaldo Krzesinski wrote:
> > > Em Qui, 2011-02-10 às 21:00 +0000, Colin Ian King escreveu:
> > > From what I remember and from experience (correct me if I say something
> > > wrong), vendors usually implement hotkeys:
> > > - using a WMI interface, where a driver needs to be written. The driver
> > > receives a WMI notification and calls wmi_evaluate_method (WMXX) to get
> > > the response/data so if the event is a hotkey it gets a code and
> > > translates it to input layer. It's a lot easier if the vendor gives
> > > information on its WMI implementation, as by nature of ACPI-WMI every
> > > vendor can choose what parameters/format to accept on WMI methods etc.
> > 
> > Yep, good one and becoming more frequent. As documented here:
> > https://wiki.ubuntu.com/Kernel/Reference/WMI
> > 
> > Personally, I'd like to write a MOF disassembler to extract a high level
> > view of the WMI configuration from the WQxx objects rather than by
> > poking around and figuring out how these work by trial-and-error...
> > when I have time.. :-)
> 
> Nice, would be great to have such tool.
> 
> I remembered now, there is also the paramters of wmi module that were
> added "recently" to the kernel (2.6.35) and are very useful, specially
> in detecting if the machine has wmi objects and if we are receiving
> things through wmi.
> wmi.debug_dump_wdg=1 to list wmi interfaces
> wmi.debug_event=1 to show on dmesg events we received

Many of these module parameters can be modified via /sys after the
module is loaded.  Well they all can, but most have an effect after.
So you might be able to turn these on and off while booted for testing:

	echo 1 >/sys/modules/wmi/parameters/debug_event
	<testing>
	echo 0 >/sys/modules/wmi/parameters/debug_event

Worth a test and adding to the docs if it works.

-apw




More information about the kernel-team mailing list