diff options
author | Scott Chao <scott_chao@wistron.corp-partner.google.com> | 2020-11-03 09:04:43 +0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-11-12 04:12:47 +0000 |
commit | 7f0c15e6d2accd3aec28c93ff7add11268e3e6c7 (patch) | |
tree | 3a4b8beaee33cfa6e57e0e9caa144c68df7bda49 /baseboard/volteer/cbi_ec_fw_config.h | |
parent | a9691611c515d7ef57aa69d738909d607461b7b1 (diff) | |
download | chrome-ec-7f0c15e6d2accd3aec28c93ff7add11268e3e6c7.tar.gz |
eldrid: add FW_CONFIG support for different keyboard layout
BUG=b:172133632
BRANCH=firmware-volteer-13521.B-master
TEST=make buildall
TEST=
ectool cbi get = 0x14902
ectool cbi set 0x114902 4
Signed-off-by: Scott Chao <scott_chao@wistron.corp-partner.google.com>
Change-Id: I0decd978bf6c21dddd315857bb1a29ac20dbf276
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2528732
Reviewed-by: Keith Short <keithshort@chromium.org>
Diffstat (limited to 'baseboard/volteer/cbi_ec_fw_config.h')
-rw-r--r-- | baseboard/volteer/cbi_ec_fw_config.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/baseboard/volteer/cbi_ec_fw_config.h b/baseboard/volteer/cbi_ec_fw_config.h index 5b97f778ec..0a44e1f9e4 100644 --- a/baseboard/volteer/cbi_ec_fw_config.h +++ b/baseboard/volteer/cbi_ec_fw_config.h @@ -43,6 +43,11 @@ enum ec_cfg_numeric_pad_type { NUMERIC_PAD_ENABLED = 1 }; +enum ec_cfg_keyboard_layout { + KB_LAYOUT_DEFAULT = 0, + KB_LAYOUT_1 = 1 +}; + union volteer_cbi_fw_config { struct { enum ec_cfg_usb_db_type usb_db : 4; @@ -53,7 +58,8 @@ union volteer_cbi_fw_config { enum ec_cfg_keyboard_backlight_type kb_bl : 1; enum ec_cfg_numeric_pad_type num_pad : 1; uint32_t sd_db : 4; - uint32_t reserved_2 : 12; + enum ec_cfg_keyboard_layout kb_layout : 2; + uint32_t reserved_2 : 10; }; uint32_t raw_value; }; @@ -108,4 +114,11 @@ bool ec_cfg_has_keyboard_backlight(void); */ bool ec_cfg_has_numeric_pad(void); +/** + * Get keyboard type from FW_CONFIG. + * + * @return the keyboard type. + */ +enum ec_cfg_keyboard_layout ec_cfg_keyboard_layout(void); + #endif /* __VOLTEER_CBI_EC_FW_CONFIG_H_ */ |