mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2025-11-24 02:05:01 +00:00
vboot_api_kernel: Print warning in TONORM when GBB flags force DEV.
We use gbb-flag-force-dev-switch-on in default firmware images to make
things easier for factory and some devs.
But when we request normal mode there should be some sort of warning/error
telling the user that this is not available, 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, set GBB flags to 0x39, boot to DEV screen
and press SPACE (TONORM); gets beep and warning messages.
Change-Id: Id48c12693c7575001fae7fad92a868cb5465e83d
Reviewed-on: https://gerrit.chromium.org/gerrit/34172
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
This commit is contained in:
@@ -201,6 +201,15 @@ VbError_t VbBootDeveloper(VbCommonParams* cparams, LoadKernelParams* p) {
|
|||||||
if (shared->flags & VBSD_HONOR_VIRT_DEV_SWITCH &&
|
if (shared->flags & VBSD_HONOR_VIRT_DEV_SWITCH &&
|
||||||
shared->flags & VBSD_BOOT_DEV_SWITCH_ON) {
|
shared->flags & VBSD_BOOT_DEV_SWITCH_ON) {
|
||||||
VbAudioClose(audio); /* Stop the countdown while we go ask... */
|
VbAudioClose(audio); /* Stop the countdown while we go ask... */
|
||||||
|
if (gbb->flags & GBB_FLAG_FORCE_DEV_SWITCH_ON) {
|
||||||
|
/* TONORM won't work (only for non-shipping devices). */
|
||||||
|
VBDEBUG(("%s() - TONORM rejected by GBB_FLAG_FORCE_DEV_SWITCH_ON\n",
|
||||||
|
__func__));
|
||||||
|
VbExDisplayDebugInfo("WARNING: TONORM is prohibited by "
|
||||||
|
"GBB_FLAG_FORCE_DEV_SWITCH_ON.\n\n");
|
||||||
|
VbExBeep(120, 400);
|
||||||
|
break;
|
||||||
|
}
|
||||||
VbDisplayScreen(cparams, VB_SCREEN_DEVELOPER_TO_NORM, 0, &vnc);
|
VbDisplayScreen(cparams, VB_SCREEN_DEVELOPER_TO_NORM, 0, &vnc);
|
||||||
switch (VbUserConfirms(cparams, 0)) { /* Ignore space */
|
switch (VbUserConfirms(cparams, 0)) { /* Ignore space */
|
||||||
case 1:
|
case 1:
|
||||||
|
|||||||
Reference in New Issue
Block a user