summaryrefslogtreecommitdiff
path: root/board/nami/board.c
diff options
context:
space:
mode:
authorRajat Jain <rajatja@google.com>2020-04-03 00:58:13 -0700
committerCommit Bot <commit-bot@chromium.org>2020-04-21 21:32:50 +0000
commitd4105005da492f8e20619cad88fdb15d6dee098f (patch)
tree44a9dc663c5d0e403ce254ff7d733631e3581b40 /board/nami/board.c
parentd2b73ad856c4ba697a2dfd8c4bf4263ffc18a5ce (diff)
downloadchrome-ec-d4105005da492f8e20619cad88fdb15d6dee098f.tar.gz
common: Make scancode table always mutable
Since the vivaldi requires the scancode to be mutable, and vivaldi shall be enabled by default for all boards, thus make the scancode table to be always mutable and get rid of the config option it hides behind. BUG=b:146501925 TEST=Build BRANCH=firmware-hatch-12672.B Signed-off-by: Rajat Jain <rajatja@google.com> Change-Id: Iaedcd6d84caf31c91a61854f96414bcea38f5c2a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2133825 Reviewed-by: Jett Rink <jettrink@chromium.org>
Diffstat (limited to 'board/nami/board.c')
-rw-r--r--board/nami/board.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/board/nami/board.c b/board/nami/board.c
index 358b0bbf22..a5d38bd0d8 100644
--- a/board/nami/board.c
+++ b/board/nami/board.c
@@ -1034,13 +1034,16 @@ static void board_init(void)
/* No need to swap scancode_set2[0][3] and [1][0] because both
* are mapped to search key. */
}
- if (sku & SKU_ID_MASK_UK2)
+ if (sku & SKU_ID_MASK_UK2) {
/*
* Observed on Shyvana with UK keyboard,
* \|: 0x0061->0x61->0x56
* r-ctrl: 0xe014->0x14->0x1d
*/
- swap(scancode_set2[0][4], scancode_set2[7][2]);
+ uint16_t tmp = get_scancode_set2(4, 0);
+ set_scancode_set2(4, 0, get_scancode_set2(2, 7));
+ set_scancode_set2(2, 7, tmp);
+ }
#endif
isl923x_set_ac_prochot(CHARGER_SOLO, 3328 /* mA */);