summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Reinauer <reinauer@chromium.org>2012-01-17 10:39:19 -0800
committerStefan Reinauer <reinauer@chromium.org>2012-01-17 10:43:16 -0800
commit1e8ddf9369369fd53e98c7d612c3d0cfeb7c9f4d (patch)
treef2e2f25ebc760f5a8616e3841e725d94fb21552b
parente10a5b02ed5e218a3a725d576456a05335408eed (diff)
downloadvboot-1e8ddf9369369fd53e98c7d612c3d0cfeb7c9f4d.tar.gz
Clean up return codes for better interaction with U-Boot.
BUG=none TEST=none Reviewed-on: https://gerrit.chromium.org/gerrit/14181 Tested-by: Bill Richardson <wfrichar@chromium.org> Reviewed-by: Randall Spangler <rspangler@chromium.org> Commit-Ready: Bill Richardson <wfrichar@chromium.org> (cherry picked from commit 82e69b9f7494c5f939e2b546c06eeb13d68bdd03) Change-Id: I1c9dc689a287b7df3118dd0ba930edb0f1744e7c Reviewed-on: https://gerrit.chromium.org/gerrit/14298 Tested-by: Stefan Reinauer <reinauer@chromium.org> Reviewed-by: Bill Richardson <wfrichar@chromium.org>
-rw-r--r--firmware/include/vboot_api.h10
-rw-r--r--firmware/lib/vboot_api_kernel.c2
2 files changed, 7 insertions, 5 deletions
diff --git a/firmware/include/vboot_api.h b/firmware/include/vboot_api.h
index b9f9f4a6..3134eee6 100644
--- a/firmware/include/vboot_api.h
+++ b/firmware/include/vboot_api.h
@@ -53,7 +53,7 @@ enum VbErrorPredefined_t {
VBERROR_INIT_SHARED_DATA = 0x10001,
/* Error resuming TPM during a S3 resume */
VBERROR_TPM_S3_RESUME = 0x10002,
- /* LoadFirmware() failed to find a valid firmware */
+ /* VbSelectFirmware() failed to find a valid firmware */
VBERROR_LOAD_FIRMWARE = 0x10003,
/* Unable to write firmware versions to TPM */
VBERROR_TPM_WRITE_FIRMWARE = 0x10004,
@@ -81,9 +81,9 @@ enum VbErrorPredefined_t {
VBERROR_NO_KERNEL_FOUND = 0x1000F,
/* All OS kernels found were invalid (corrupt, improperly signed, etc.) */
VBERROR_INVALID_KERNEL_FOUND = 0x10010,
- /* LoadKernel() requested recovery mode */
+ /* VbSelectAndLoadKernel() requested recovery mode */
VBERROR_LOAD_KERNEL_RECOVERY = 0x10011,
- /* Other error inside LoadKernel() */
+ /* Other error inside VbSelectAndLoadKernel() */
VBERROR_LOAD_KERNEL = 0x10012,
/* Invalid Google binary block */
VBERROR_INVALID_GBB = 0x10013,
@@ -98,7 +98,9 @@ enum VbErrorPredefined_t {
/* VbExBeep() can't make sounds at all */
VBERROR_NO_SOUND = 0x10018,
/* VbExBeep() can't make sound in the background */
- VBERROR_NO_BACKGROUND_SOUND = 0x10019
+ VBERROR_NO_BACKGROUND_SOUND = 0x10019,
+ /* Developer has requested a BIOS shell */
+ VBERROR_BIOS_SHELL_REQUESTED = 0x10020
};
diff --git a/firmware/lib/vboot_api_kernel.c b/firmware/lib/vboot_api_kernel.c
index 6715e86f..5dd5609c 100644
--- a/firmware/lib/vboot_api_kernel.c
+++ b/firmware/lib/vboot_api_kernel.c
@@ -142,7 +142,7 @@ VbError_t VbBootDeveloper(VbCommonParams* cparams, LoadKernelParams* p) {
VBDEBUG(("VbBootDeveloper() - user pressed ENTER/SPACE/ESC\n"));
VbSetRecoveryRequest(VBNV_RECOVERY_RW_DEV_SCREEN);
VbAudioClose(audio);
- return 1;
+ return VBERROR_LOAD_KERNEL_RECOVERY;
case 0x04:
/* Ctrl+D = dismiss warning; advance to timeout */
VBDEBUG(("VbBootDeveloper() - user pressed Ctrl+D; skip delay\n"));