vboot_api_kernel: Print warning in Ctrl-U when dev_boot_usb is not enabled.

Ctrl-U used to simply beep without messages for why it does not work (due to NV
data dev_boot_usb). Since the system is already in Developer mode, it should be
fine to provide some debug information otherwise we can spent time trying to
figure out why the firmware doesn't work.

BRANCH=all
BUG=chrome-os-partner:14474
TEST=flash image to Link, enter DEV and press Ctrl-U; gets beep and warning messages.

Change-Id: Iab20ecdb2e1c4e267b7257a7bd241006241ddf70
Reviewed-on: https://gerrit.chromium.org/gerrit/34406
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
This commit is contained in:
Hung-Te Lin
2012-10-02 16:24:45 +08:00
committed by Gerrit
parent cb85206ebf
commit 00311b8644

View File

@@ -260,6 +260,9 @@ VbError_t VbBootDeveloper(VbCommonParams* cparams, LoadKernelParams* p) {
VBDEBUG(("VbBootDeveloper() - user pressed Ctrl+U; try USB\n"));
if (!allow_usb) {
VBDEBUG(("VbBootDeveloper() - USB booting is disabled\n"));
VbExDisplayDebugInfo("WARNING: Booting from external media (USB/SD) "
"has not been enabled. Refer to the "
"developer-mode documentation for details.\n");
VbExBeep(120, 400);
VbExSleepMs(120);
VbExBeep(120, 400);