summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShawn Nematbakhsh <shawnn@google.com>2012-10-30 15:17:33 -0700
committerSimon Glass <sjg@chromium.org>2012-11-13 13:52:34 -0800
commita4c92cb149aec7143b6f552d1456f8a0475cc17f (patch)
tree307a4da20aee2cd93a75bd44f714a8b12ffb5469
parent08ed1b3b2403d40204cb6641678b9a01b27aea7d (diff)
downloadvboot-firmware-snow-2695.B.tar.gz
vboot_reference: Fix keyboard input lag at confirm screen.firmware-snow-2695.B
Changing languages is terribly slow at the confirm screen, when switching from dev to normal. Reduce sleep time to improve user experience. BUG=chrome-os-partner:15726 TEST=boot in dev, hit space, hit arrows rapidly to change language, observe no lag. BRANCH=butterfly, stout Change-Id: I0943debc31d78dcfce87e7f7d4537ae47f5f8cfd Reviewed-on: https://gerrit.chromium.org/gerrit/36956 Reviewed-by: Duncan Laurie <dlaurie@chromium.org> Reviewed-by: Bill Richardson <wfrichar@chromium.org> Commit-Ready: Shawn Nematbakhsh <shawnn@google.com> Tested-by: Shawn Nematbakhsh <shawnn@google.com> Reviewed-by: Randall Spangler <rspangler@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/37938 Tested-by: Simon Glass <sjg@chromium.org>
-rw-r--r--firmware/lib/vboot_api_kernel.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/firmware/lib/vboot_api_kernel.c b/firmware/lib/vboot_api_kernel.c
index a35fd31a..ffcb75ce 100644
--- a/firmware/lib/vboot_api_kernel.c
+++ b/firmware/lib/vboot_api_kernel.c
@@ -105,6 +105,8 @@ uint32_t VbTryLoadKernel(VbCommonParams* cparams, LoadKernelParams* p,
return retval;
}
+#define CONFIRM_KEY_DELAY 20 /* Check confirm screen keys every 20ms */
+
/* Ask the user to confirm something. We should display whatever the question
* is first, then call this. ESC is always "no", ENTER is always "yes", and
* we'll specify what SPACE means. We don't return until one of those keys is
@@ -139,7 +141,7 @@ static int VbUserConfirms(VbCommonParams* cparams, int space_means_no) {
default:
VbCheckDisplayKey(cparams, key, &vnc);
}
- VbExSleepMs(1000);
+ VbExSleepMs(CONFIRM_KEY_DELAY);
}
/* not reached, but compiler will complain without it */
return -1;