diff options
author | Todd Broch <tbroch@chromium.org> | 2014-09-03 16:56:12 -0700 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2014-09-03 17:07:05 -0700 |
commit | 017f14e88bf15ca96eb377b3b14fc3c3332e6b9b (patch) | |
tree | 358f0ae1a095964bbb9c4aaadf00b89507534b5e /drivers/input/joystick | |
parent | 516d5f8b04ce2bcd24f03323fc743ae25b81373d (diff) |
Input: cros_ec_keyb - optimize ghosting algorithm
Previous algorithm was a bit conservative and complicating with respect to
identifying key ghosting. This CL uses the bitops hamming weight function
(hweight8) to count the number of matching rows for colM & colN. If that
number is > 1 ghosting is present.
Additionally it removes NULL keys and our one virtual keypress KEY_BATTERY
from consideration as these inputs are never physical keypresses.
Signed-off-by: Todd Broch <tbroch@chromium.org>
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Luigi Semenzato <semenzato@chromium.org>
Tested-by: Andreas Färber <afaerber@suse.de>
Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/joystick')
0 files changed, 0 insertions, 0 deletions