Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(269)

Unified Diff: host/lib/crossystem.c

Issue 6597011: Add NV storage fields for firmware flags (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/vboot_reference.git@master
Patch Set: Created 9 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « firmware/lib/vboot_nvstorage.c ('k') | tests/vboot_nvstorage_test.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: host/lib/crossystem.c
diff --git a/host/lib/crossystem.c b/host/lib/crossystem.c
index 9428ba526431fcef33ac2242cc3059cd7dc07ccc..164c87c2194830882699a3bd93c141d209ba9b60 100644
--- a/host/lib/crossystem.c
+++ b/host/lib/crossystem.c
@@ -484,6 +484,10 @@ int VbGetSystemPropertyInt(const char* name) {
} else if (!strcasecmp(name,"savedmem_size")) {
return (-1 == ReadFileInt(ACPI_CHSW_PATH) ? -1 : 0x00100000);
}
+ /* NV storage values with no defaults for older BIOS. */
+ else if (!strcasecmp(name,"fwb_try_used")) {
Bill Richardson 2011/02/25 19:18:31 Why do we call the parameter "b_try_used" instead
Randall Spangler 2011/02/25 19:22:04 How about tried_fwb
+ value = VbGetNvStorage(VBNV_FW_USED_TRY_B);
+ }
/* NV storage values. If unable to get from NV storage, fall back to the
* CMOS reboot field used by older BIOS. */
else if (!strcasecmp(name,"recovery_request")) {
@@ -548,6 +552,15 @@ const char* VbGetSystemPropertyString(const char* name, char* dest, int size) {
default:
return NULL;
}
+ } else if (!strcasecmp(name,"kernkey_vfy")) {
+ switch(VbGetNvStorage(VBNV_FW_VERIFIED_KERNEL_KEY)) {
+ case 0:
+ return "hash";
+ case 1:
+ return "sig";
+ default:
+ return NULL;
+ }
} else
return NULL;
}
« no previous file with comments | « firmware/lib/vboot_nvstorage.c ('k') | tests/vboot_nvstorage_test.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698