]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Add KEY_MICMUTE and enable it on Lenovo X220
authorAndy Lutomirski <luto@MIT.EDU>
Tue, 24 May 2011 19:16:43 +0000 (15:16 -0400)
committerMatthew Garrett <mjg@redhat.com>
Mon, 11 Jul 2011 13:43:21 +0000 (09:43 -0400)
I suspect that this works on T410.

Signed-off-by: Andy Lutomirski <luto@mit.edu>
Signed-off-by: Matthew Garrett <mjg@redhat.com>
drivers/platform/x86/thinkpad_acpi.c
include/linux/input.h

index 26c5b117df22d5011c46c64f2f588f83dd7ed58c..7bd829f247eb5ae98fa3b2c61914d16cf554a941 100644 (file)
@@ -3185,9 +3185,18 @@ static int __init hotkey_init(struct ibm_init_struct *iibm)
 
                KEY_VENDOR,     /* 0x17: Thinkpad/AccessIBM/Lenovo */
 
+               /* (assignments unknown, please report if found) */
+               KEY_UNKNOWN, KEY_UNKNOWN,
+
+               /*
+                * The mic mute button only sends 0x1a.  It does not
+                * automatically mute the mic or change the mute light.
+                */
+               KEY_MICMUTE,    /* 0x1a: Mic mute (since ?400 or so) */
+
                /* (assignments unknown, please report if found) */
                KEY_UNKNOWN, KEY_UNKNOWN, KEY_UNKNOWN, KEY_UNKNOWN,
-               KEY_UNKNOWN, KEY_UNKNOWN, KEY_UNKNOWN, KEY_UNKNOWN,
+               KEY_UNKNOWN,
                },
        };
 
index 771d6d85667d68a17c24c452979f8d37cc628082..f26d3b7b37dd8ca90d2d0113d0ab252b28f250b3 100644 (file)
@@ -438,6 +438,8 @@ struct input_keymap_entry {
 #define KEY_WIMAX              246
 #define KEY_RFKILL             247     /* Key that controls all radios */
 
+#define KEY_MICMUTE            248     /* Mute / unmute the microphone */
+
 /* Code 255 is reserved for special needs of AT keyboard driver */
 
 #define BTN_MISC               0x100