]> git.baikalelectronics.ru Git - kernel.git/commit
Input: cros_ec_keyb - fix problems with backslash
authorDoug Anderson <dianders@chromium.org>
Mon, 30 Dec 2013 00:52:46 +0000 (16:52 -0800)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Tue, 31 Dec 2013 18:45:29 +0000 (10:45 -0800)
commit2f2702da97b9f8eaea45154bfbf76cdb0f8d3308
tree85c86d0de409b978da2c94a6bde098c8d976d279
parent766fc7dc86f575de3c6cb9357f43e71545518d18
Input: cros_ec_keyb - fix problems with backslash

The driver can't deal with two entries its keymap having the same keycode.
When this happens it will get confused about whether the key is down or up
and will cause some screwy behavior.

We need to have two entries for KEY_BACKSLASH to handle US and UK
keyboards. Specifically:
* On the US keyboard the backslash key (above enter) is r3 c11 and is
  supposed to be reported as BACKSLASH.
* On the UK keyboard the # key (left of enter) is r4 c10 and is
  supposed to be reported as BACKSLASH.
* On the UK keyboard the \ key (left of Z) is r2 c7 and is supposed to
  be reported as KEY_102ND.

Note that both keyboards (US and UK) have only one physical backslash
key so the constraint that each physical key should have its own keycode
still stands.

Signed-off-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/keyboard/cros_ec_keyb.c