While previous ghosting fix:
688c20f CHROMIUM: Strengthen ghosting algorithm.
Did help rule out null keys it was thought it would also correctly
identify 3 vs. 4 keypresses (sharing row/col) regardless of whether
key was virtual (KEY_BATTERY) or real. It does not however.
This change migrates KEY_BATTERY to invalid key while algorithm is
further refined.
BUG=chrome-os-partner:18814
TEST=manual
boot Spring plugged after an EC reset and see no ghosting issues for
sequences ctrl + u|w|n|t
Change-Id: I1038a18c353e84a52ad77e44e497c747d310addf
Signed-off-by: Todd Broch <tbroch@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/48674
Reviewed-by: Luigi Semenzato <semenzato@chromium.org>
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
for (col = 0; col < MKBP_NUM_COLS; col++) {
for (row = 0; row < MKBP_NUM_ROWS; row++) {
code = mkbp_keycodes[row][col];
- if (code)
+ if (code && (code != KEY_BATTERY))
mkbp_dev->valid_keys[col] |= 1 << row;
}
dev_dbg(mkbp_dev->dev, "valid_keys[%02d] = 0x%02x\n",