Skip to contentSkip to conversation

Remap MSI Laptop touchpad on/off key to F22 and F23

PATCH Martin Pitt 2 participants 2 messages Mar 18, 2011 – Mar 22, 2011

lore
Share & tools
lore
#0 lore raw

Hello Joey,

Joey Lee [2011-03-16 1:06 -0600]:

Quoted 10 lines

P: /devices/virtual/input/input7
E: UDEV_LOG=3
E: DEVPATH=/devices/virtual/input/input7
E: PRODUCT=19/0/0/0
E: NAME="MSI Laptop hotkeys"
E: PHYS="msi-laptop/input0"
E: EV==3
E: KEY==180000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
E: MODALIAS=input:b0019v0000p0000e0000-e0,1,k213,214,ramlsfw
E: SUBSYSTEM=input

Ah, thanks for this data. This indeed helped to demonstrate the problem. First I added some debugging output to input_id [1].

While debugging I got an overflow, because your data is apparently from a 32 bit machine/kernel, while I'm running 64 bit. I fixed that as well while I was at it [2]. After fudging the data to be in the proper 64 bit format, I was able to see what the KEY_MAX problem was. Unfortunately the KEY_* and BTN_* blocks are alternating in linux/input.h, so the fix looks a bit unelegant, but it works now [3].

Thanks!

Martin

[1] http://git.kernel.org/?p=linux/hotplug/udev.git;a=commitdiff;h=941c40bdc47d1fdee651558dd0e162cd8d674fab
[2] http://git.kernel.org/?p=linux/hotplug/udev.git;a=commitdiff;h=88149f668ea7ac23c61f6d1982db4f4517da763c
[3] http://git.kernel.org/?p=linux/hotplug/udev.git;a=commitdiff;h=792479aca54d266430c900f90557ea8d0da2c125

Signature · 2 lines
Martin Pitt                        | http://www.piware.de
Ubuntu Developer (www.ubuntu.com)  | Debian Developer  (www.debian.org)
#1 lore raw

Re: Fwd: [PATCH] Remap MSI Laptop touchpad on/off key to F22

Hi Martin,

於 五,2011-03-18 於 14:55 +0100,Martin Pitt �到:

Quoted 24 lines

Hello Joey,

Joey Lee [2011-03-16 1:06 -0600]:

Quoted 10 lines

P: /devices/virtual/input/input7
E: UDEV_LOG=3
E: DEVPATH=/devices/virtual/input/input7
E: PRODUCT/0/0/0
E: NAME="MSI Laptop hotkeys"
E: PHYS="msi-laptop/input0"
E: EV=3
E: KEY=180000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
E: MODALIAS=input:b0019v0000p0000e0000-e0,1,k213,214,ramlsfw
E: SUBSYSTEM=input

Ah, thanks for this data. This indeed helped to demonstrate the problem. First I added some debugging output to input_id [1].

While debugging I got an overflow, because your data is apparently from a 32 bit machine/kernel, while I'm running 64 bit. I fixed that as well while I was at it [2]. After fudging the data to be in the proper 64 bit format, I was able to see what the KEY_MAX problem was. Unfortunately the KEY_* and BTN_* blocks are alternating in linux/input.h, so the fix looks a bit unelegant, but it works now [3].

Quoted 7 lines

Thanks!

Martin

[1] http://git.kernel.org/?p=linux/hotplug/udev.git;a=commitdiff;h”1c40bdc47d1fdee651558dd0e162cd8d674fab
[2] http://git.kernel.org/?p=linux/hotplug/udev.git;a=commitdiff;hˆ149f668ea7ac23c61f6d1982db4f4517da763c
[3] http://git.kernel.org/?p=linux/hotplug/udev.git;a=commitdiff;hy2479aca54d266430c900f90557ea8d0da2c125

I applied the above patches to udev 166 and it works fine with my msi-laptop driver's input device. :-)

Thank's a lot!
Joey Lee