summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Hendricks <dhendrix@chromium.org>2012-05-08 15:52:49 -0700
committerDavid Hendricks <dhendrix@chromium.org>2012-05-08 17:06:17 -0700
commita2efa4472aa028db7668bf03887fa267eb4414bc (patch)
tree3aa74f796728a7f85c2bf2ba948293e23dc3783c
parent87b427829993e7c5b2fb66fc1e134ace43d28cf9 (diff)
downloadchrome-ec-a2efa4472aa028db7668bf03887fa267eb4414bc.tar.gz
stm32: Fix an off-by-one error in select_column()
This fixes an off-by-one error that was preventing two keys (left and right arrow) on output 12 from being driven properly, and causing some other weird ghosting effects. BUG=chrome-os-partner:9516 TEST=Tested on Daisy Pressing the right arrow shows this at the EC console: [1 keys pressed: -- -- -- -- -- -- -- -- -- -- -- -- 40] and pressing the left arrow shows this at the EC console: [1 keys pressed: -- -- -- -- -- -- -- -- -- -- -- -- 80] Signed-off-by: David Hendricks <dhendrix@chromium.org> Change-Id: Ib7af21444c2d03a0787fb1a28b520a779013774d
-rw-r--r--chip/stm32/keyboard_scan.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/chip/stm32/keyboard_scan.c b/chip/stm32/keyboard_scan.c
index b3d340172e..699625085f 100644
--- a/chip/stm32/keyboard_scan.c
+++ b/chip/stm32/keyboard_scan.c
@@ -87,7 +87,7 @@ static void select_column(int col)
uint32_t bsrr = 0;
int j;
- for (j = GPIO_KB_OUT00; j < GPIO_KB_OUT12; j++) {
+ for (j = GPIO_KB_OUT00; j <= GPIO_KB_OUT12; j++) {
if (gpio_list[j].port != ports[i])
continue;