From 8a8af6c10ee6973d17b818f65311fc6f12925f09 Mon Sep 17 00:00:00 2001 From: Duncan Laurie Date: Wed, 14 Dec 2016 11:44:58 -0800 Subject: [PATCH] eve: Increase keyscan output settle time to 80us Increase the output settle time to 80us from the default 50us to prevent duplicate keys. BUG=chrome-os-partner:58666 BRANCH=none TEST=build and boot on eve Change-Id: Ied1acef0b763b9a321f7fe36477eee6e467ce17f Signed-off-by: Duncan Laurie Reviewed-on: https://chromium-review.googlesource.com/419825 Commit-Ready: Duncan Laurie Tested-by: Duncan Laurie Reviewed-by: Daisuke Nojiri --- board/eve/board.c | 14 ++++++++++++++ board/eve/board.h | 3 ++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/board/eve/board.c b/board/eve/board.c index 5598c9aaad..c3d645fd47 100644 --- a/board/eve/board.c +++ b/board/eve/board.c @@ -96,6 +96,20 @@ const struct power_signal_info power_signal_list[] = { }; BUILD_ASSERT(ARRAY_SIZE(power_signal_list) == POWER_SIGNAL_COUNT); +/* Keyboard scan. Increase output_settle_us to 80us from default 50us. */ +struct keyboard_scan_config keyscan_config = { + .output_settle_us = 80, + .debounce_down_us = 9 * MSEC, + .debounce_up_us = 30 * MSEC, + .scan_period_us = 3 * MSEC, + .min_post_scan_delay_us = 1000, + .poll_timeout_us = 100 * MSEC, + .actual_key_mask = { + 0x14, 0xff, 0xff, 0xff, 0xff, 0xf5, 0xff, + 0xa4, 0xff, 0xfe, 0x55, 0xfa, 0xca /* full set */ + }, +}; + /* PWM channels. Must be in the exactly same order as in enum pwm_channel. */ const struct pwm_t pwm_channels[] = { [PWM_CH_KBLIGHT] = { 5, PWM_CONFIG_DSLEEP, 100 }, diff --git a/board/eve/board.h b/board/eve/board.h index 2e6235064d..7fd184f182 100644 --- a/board/eve/board.h +++ b/board/eve/board.h @@ -26,7 +26,6 @@ #define CONFIG_FPU #define CONFIG_I2C #define CONFIG_I2C_MASTER -#define CONFIG_KEYBOARD_COL2_INVERTED #define CONFIG_LID_SWITCH #define CONFIG_LTO #define CONFIG_PWM @@ -53,6 +52,8 @@ #define CONFIG_ESPI #define CONFIG_ESPI_VW_SIGNALS #define CONFIG_LPC +#define CONFIG_KEYBOARD_BOARD_CONFIG +#define CONFIG_KEYBOARD_COL2_INVERTED #define CONFIG_KEYBOARD_PROTOCOL_8042 /* Battery */