# Re: \[PATCH 1/3\] Add acer wmi hotkey events support

- From: Joey Lee \<hidden\>
- Date: 2010-10-19 09:35:48 
- List: linux-input
- Page: https://ratatoskr.run/linux-input/2010/10/8915218
- Thread: https://ratatoskr.run/linux-input/2010/10/8915218/t.md

```text
Hi Dmitry, 

於 一，2010-10-18 於 01:25 -0700，Dmitry Torokhov 提到：
> On Mon, Oct 18, 2010 at 10:19:37AM +0200, Corentin Chary wrote:
> > On Mon, Oct 18, 2010 at 10:12 AM, Dmitry Torokhov
> > [ref] wrote:
> > > On Sun, Oct 17, 2010 at 10:53:04PM -0600, Joey Lee wrote:
> > >> +static const struct key_entry acer_wmi_keymap[] = {
> > >> +     {KE_KEY, 0x01, {KEY_WLAN} },     /* WiFi */
> > >> +     {KE_KEY, 0x12, {KEY_BLUETOOTH} },       /* BT */
> > >> +     {KE_KEY, 0x21, {KEY_PROG1} },    /* Backup */
> > >> +     {KE_KEY, 0x22, {KEY_PROG2} },    /* Aracade */
> > >> +     {KE_KEY, 0x23, {KEY_PROG3} },    /* P_Key */
> > >> +     {KE_KEY, 0x24, {KEY_PROG4} },    /* Social networking_Key */
> > >> +     {KE_KEY, 0x64, {KEY_SWITCHVIDEOMODE} }, /* Display Switch */
> > >> +     {KE_KEY, 0x82, {KEY_F22} },      /* Touch Pad On/Off */
> > >
> > > We need to standardize this. Some people use F13/F14, here we have
> > > F22...
> > >
> > 
> > The good thing with F* keys, is that they are already mapped in X/Qt/SDL/etc..
> > 
> > But if we do, we could add KEY_TOUCHPADTOGGLE 0x1b8
> > Then bind it to XF86XK_TouchpadToggle (what's the right way to do that
> > ? keymaps ?)
> > 
> 
> I wonder who the main consumers of such events will be... X applications
> or daemons that listen turn this into some DBUS signal...
> 

As I know,
X-input will transfer the keycode to x-keycode (XF22), then mapping the
x-keycode to x-symbol (XF86XK_TouchpadToggle).
Then some daemon or userland applications can grab it.

Thank's
Joey Lee
```
