Bug 20153

Summary: broken keymap override for Thinkpad keys
Product: hal Reporter: Marcus Better <marcus>
Component: hal-infoAssignee: David Zeuthen (not reading bugmail) <zeuthen>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium CC: corsac, danny.kukawka
Version: unspecified   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description Marcus Better 2009-02-17 01:33:55 UTC
The file

  /usr/share/hal/fdi/information/10freedesktop/30-keymap-module-thinkpad-acpi.fdi

contains overrides of the keymap for the thinkpad-acpi driver. This is actually harmful since
 (a) there should be no need to mess with the keymap of thinkpad-acpi [1], and
 (b) the provided keymap is broken anyway.

For instance the line

  <append key="input.keymap.data" type="strlist">0x04:radio</append> <!-- Fn+F5 switch radio -->

maps the Fn+F5 button to KEY_RADIO, when it should be KEY_WLAN. The
latter is what the rfkill input layer reacts to.

I think the entire file should just be removed.

See also the Debian bug report [2].

[1] http://permalink.gmane.org/gmane.linux.hardware.thinkpad/37120
[2] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=504643
Comment 1 Yves-Alexis 2009-04-19 23:24:30 UTC
KEY_WLAN and/or KEY_BLUETOOTH btw :) Not sure about most people but I definitely disable more often the bluetooth than the wlan (for people with bluetooth, I mean).
Comment 2 Martin Pitt 2009-06-17 03:12:23 UTC
Fixed in udev extras/keymap (which replaces hal):

http://git.kernel.org/?p=linux/hotplug/udev.git;a=commitdiff;h=0fb7c5184678821060843824a26514946a3b9302
Comment 3 Danny Kukawka 2009-07-28 01:45:23 UTC
commit e0d95232f8f363b7f08f1b21c7ff5ac74621ee5a
Author: Bjørn Mork <bjorn@mork.no>
Date:   Sun Jun 28 22:13:37 2009 +0200

    fix ThinkPad Fn+F5 wlan key

    hal-info maps the Fn+F5 Thinkpad key to KEY_RADIO, which is
    a) not correct
    b) outside the X input usable range

    This is reported as bugs
     http://bugs.freedesktop.org/show_bug.cgi?id=20153
     http://bugs.debian.org/504643

    The attached patch fixes the problem by changing the mapping to
    KEY_WLAN.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.